Lewin's blog

By Lewin, history, 9 years ago, In English

Hello everyone!

Another year has gone by. The last Codeforces contest of this year will be tomorrow, 29 Dec, 15:35 UTC.

The round details:

  • combined div1+div2
  • 8 problems
  • 2.5 hours
  • rated!!!

I'd like to thank the following people for helping with the round: KAN, winger, AlexFetisov, zemen, xiaowuc1, MikeMirzayanov. Without them, this round would not have been possible.

Scoring distribution will be posted later. Make sure to read ahead on the problems, since there may be some later problems that are easier for you. I hope to see you all at the contest, and good luck on the last chance to increase your rating this year!

EDIT1: The scoring distribution is 500-750-1000-1750-1750-2000-2750-3500

EDIT2: There will be a five minute delay for starting.

EDIT3: Editorial is here: http://codeforces.me/blog/entry/56713

EDIT4: Congratulations to the winners!

  1. Petr
  2. dotorya
  3. V--o_o--V
  4. Radewoosh
  5. Endagorion
  6. rng_58
  7. PavelKunyavskiy
  8. EvenImage
  9. mmaxio
  10. Reyna
  • Vote: I like it
  • +1310
  • Vote: I do not like it

| Write comment?
»
9 years ago, hide # |
 
Vote: I like it -54 Vote: I do not like it

Is it rated or not?

»
9 years ago, hide # |
 
Vote: I like it +61 Vote: I do not like it

Be careful, you wrote "17:35 UTC" instead of "15:35 UTC".

»
9 years ago, hide # |
 
Vote: I like it +11 Vote: I do not like it

Expert this contest!! Good luck to all and have fun, hopefully 7k will participate. Thanks Mike for everything this year.

»
9 years ago, hide # |
 
Vote: I like it +13 Vote: I do not like it

Mathematically speaking, would the ratings of Div2 participants be affected in any way in a Div1 + Div2 contest as opposed to only Div2 contests?

»
9 years ago, hide # |
 
Vote: I like it -41 Vote: I do not like it

"Make sure to read ahead on the problems, since there may be some later problems that are easier for you." — smelling something fishy. Hoping it will a be memorable contest.

»
9 years ago, hide # |
 
Vote: I like it +37 Vote: I do not like it

What does the Good Bye contest say: "Long time no C"

»
9 years ago, hide # |
Rev. 2  
Vote: I like it 0 Vote: I do not like it

"Make sure to read ahead on the problems, since there may be some later problems that are easier for you"

Love the suspense! Can't wait!

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +14 Vote: I do not like it

Can't wait to participate the contest, if I don't drop to div2 I can then finally propose a CodeForces contest. :D

Note to self: Don't stay overnight for a programming contest ever again.... ZzzzzZZZZzzzz

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Wish everybody high rating in the last contest in this year and good holiday mood!

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

Happy new year codeforces !

»
9 years ago, hide # |
 
Vote: I like it -23 Vote: I do not like it

Will the ratings be calculated separately for div 1 and div2 even though we are in the same contest? I feel that, unless rating changes are calculated differently, div 2 participants will be less likely to gain rating if they are in the same pool as div 1 participants.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    that just means div1 people gain more rating!

  • »
    »
    9 years ago, hide # ^ |
    Rev. 2  
    Vote: I like it +42 Vote: I do not like it

    I think otherwise. As the cf rating formula uses rank/(expected rank) as rating change coefficient, Div. 2 participant's are expected to be after div1 ones, so if they do a bit well they could get way bigger change that normal div.2. But if div1 gets beaten by few div2 people he'll farther from first place whereas expected ranks stays the same.

    PS. Out of my experience I do get biggest changes on combined rounds.

»
9 years ago, hide # |
 
Vote: I like it +102 Vote: I do not like it

I hope 2017 ends making me a Specialist.

»
9 years ago, hide # |
 
Vote: I like it +95 Vote: I do not like it

I bet for 10K+ Registrants! <3

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

So what's your New Year's Resolution ?

»
9 years ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

Are both div1 and div2 participants taken into consideration while calculating the rating change of a div2 guy?

»
9 years ago, hide # |
 
Vote: I like it -11 Vote: I do not like it

Editorial right after the contest will be great, hope you will work on it.

»
9 years ago, hide # |
 
Vote: I like it -14 Vote: I do not like it

If this contest goes unrated MikeMirzayanov will give 100 + rating to everyone , Happy coding guys and girls !

»
9 years ago, hide # |
Rev. 3  
Vote: I like it +2 Vote: I do not like it

How to solve D ? Update: I have mistakenly commented here. :p :p

»
9 years ago, hide # |
Rev. 4  
Vote: I like it +19 Vote: I do not like it

Restrations.. :p 2015  2016  2017 Pending.....

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +10 Vote: I do not like it

educational round rating update and goodbye 2017 will overlap :|

PS: For the first time you can enter a round with a rating and end it with another one!

»
9 years ago, hide # |
 
Vote: I like it +47 Vote: I do not like it

Probably Lewin is thinking of a script such:

if(comment.writer == "metsuka"){
    GetRidOfThisComment(comment);
}

P.S. : baw bekesh biroooon!

»
9 years ago, hide # |
 
Vote: I like it +13 Vote: I do not like it

LoL there is already another div2 contest in the new year!

»
9 years ago, hide # |
Rev. 3  
Vote: I like it +3 Vote: I do not like it

Why still do not turn on New Year's magic?

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +39 Vote: I do not like it

Codeforces is reliable, as usual...

»
9 years ago, hide # |
 
Vote: I like it +55 Vote: I do not like it

Considering that educational round's system-testing will happen during this contest , wouldn't it be too much of a load for the server since this contest is anyways going to have much more traffic that average?

»
9 years ago, hide # |
 
Vote: I like it +22 Vote: I do not like it

Good luck everyone on the contest and in new 2018 year!

I want to believe that codeforces will have less lags in next year then in this year!

And also thanks to the guys who created an anime-contests, they was really good. I want more anime-contests in the future, does anyone else want it too?

»
9 years ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

Will we be able to change our handles this year?

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +33 Vote: I do not like it

My rating changes at Good bye contest:

  • Good bye 2014: -114
  • Good bye 2015: -28
  • Good bye 2016: -71
  • Good bye 2017: -???
»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Won't the questions sorted by difficulty like in regular contests?

»
9 years ago, hide # |
 
Vote: I like it +10 Vote: I do not like it

Good luck to all the participants! I hope all the participants will get high rating! Happy New Year 2018!!!

»
9 years ago, hide # |
 
Vote: I like it +89 Vote: I do not like it

 I guess there must be a question on tree(Christmas tree)

»
9 years ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

Good luck. Have fun!

»
9 years ago, hide # |
Rev. 2  
Vote: I like it 0 Vote: I do not like it

I wonder if there are T-shirts for the well-performed?
I'm looking forward to that!

»
9 years ago, hide # |
 
Vote: I like it +12 Vote: I do not like it

We are waiting for Scoring distribution

»
9 years ago, hide # |
 
Vote: I like it +34 Vote: I do not like it

The contest is combined for both divisions The red contestants:

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

4500 registrations and 8.5 hours left. I think we'll have at least 8.000 participants. I hope that the site will work

»
9 years ago, hide # |
 
Vote: I like it -19 Vote: I do not like it

祝大家元旦快乐!

»
9 years ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

Happy new year Codeforces!!!

»
9 years ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

scoring distribution will be 500-750-1000-1500-2250-3000-3250-3500.

»
9 years ago, hide # |
 
Vote: I like it +56 Vote: I do not like it

Let's hope we can see the fight between tourist and EvenImage

»
9 years ago, hide # |
 
Vote: I like it +6 Vote: I do not like it

Will magic color effect be activated this year ?

»
9 years ago, hide # |
 
Vote: I like it +39 Vote: I do not like it

░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░░░░░██░░░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░░░██████░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░████████░███░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░█████████░░███░░░░░░░░░░░░░░ ░░░░░░░░░░░░░███████████░░░██░░░░░░░░░░░░░ ░░░░░░░░░░░░██████████░░░░░░██░░░░░░░░░░░░ ░░░░░░░░░░██████████░░░░░░░░░██░░░░░░░░░░░ ░░░░░░░░░░█████████░░░░░░░░░░░██░░░░░░░░░░ ░░░░░░░░░█████░░░░░░░░░░░░░░░░░██░░░░░░░░░ ░░░░░░░░████████░░░░░░░░░█████░██░░░░░░░░░ ░░░░░░░░░░░███████████████████░░░░░░░░░░░░ ░░░░░░░░░░░████████████████████░░░░░░░░░░░ ░░░░░░░░░░██████████████████████░░░░░░░░░░ ░░░░░░░░░████████████████████░░██░░░░░░░░░ ░░░░░░░░████████████████████░░░░██░░░░░░░░ ░░░░░░░████████████████░░░░░░░░░░██░░░░░░░ ░░░░░░████████████░░░░░░░░░░░░░░░░██░░░░░░ ░░░░░████░░██░░░░░░░░░░░░░░░░░░░░░░██░░░░░ ░░░░███████░░░░░░█████░░░░░░█████████░░░░░ ░░░░██░░████████████████████████░░░░░░░░░░ ░░░░░░░█████████████████████░░░██░░░░░░░░░ ░░░░░░███████████████████░████░░░██░░░░░░░ ░░░░██████████████████████░░░░░░░░░██░░░░░ ░░██████████████████████░░░░░░░░░░░░███░░░ ░███████████████░█░░░░░░░░░░░░░░░░░░░░██░░ █████████░█░░░░░░░░░░░░░░░░░░░░░░░███████░ ░░░░░░░███░░░░░░░███████░░░░░░██████░░░░░░ ░░░░░░░░███████████████████████████░░░░░░░ ░░░░░░███████████████████████████░██░░░░░░ ░░░░██████████████████████████████░███░░░░ ░░░█████████████████████████████░░░░░██░░░ ░░█████████████████████████░░░░░░░░░░░██░░ ░█████████████████████░█░░░░░░░░░░░░░░░██░ █████████████████░█░░░░░░░░░░░░░░░░░░░████ ░░░░░███████████░░░░░░░░███░░░░████████░░░ ░░░░░░░░░░░░░░░░███░█████░█████░░░░░░░░░░░ ░░░░░░░░░░░░░░░░████████░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░██████░█░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░██████░█░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░█████░░█░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░████░░░█░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░████████░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ ░░░░░░███████░░████████░░██░░███████░░░░░░ ░░░░░░░░░░░██░░██░░░░██░░██░░██░░░██░░░░░░ ░░░░░░░░░░░██░░██░░░░██░░██░░██░░░██░░░░░░ ░░░░░░███████░░██░░░░██░░██░░███████░░░░░░ ░░░░░░██░░░░░░░██░░░░██░░██░░██░░░██░░░░░░ ░░░░░░██░░░░░░░██░░░░██░░██░░██░░░██░░░░░░ ░░░░░░███████░░████████░░██░░███████░░░░░░ ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ ONE MORE TIME HAPPY NEW YEAR !!!!!!!!!!!!!!!!

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Can i change my handle?

»
9 years ago, hide # |
 
Vote: I like it -10 Vote: I do not like it

So, all the 8 problems are set by Lewin and the others who are mentioned in the post just helped to prepare the round, not setters, right? WOW ! Great !!

»
9 years ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

Wish a color-change round!

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Rush to purple or higher :)

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Is it advisable for a contestant who gets around 1000 rank in Div2 contests to participate in combined (Div1 + Div2) rounds?

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

another goodbye contest , great =)

»
9 years ago, hide # |
 
Vote: I like it +8 Vote: I do not like it

This is such a big contest! Feel a little nervous:)

Try my best to get a good ending of 2018.

Hope everyone will have a good ending in 2017 and get a higher rating in 2018.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Can every contestant get +50 without reason as a new year motivation gift? :D MikeMirzayanov

»
9 years ago, hide # |
Rev. 4  
Vote: I like it +99 Vote: I do not like it

for CF-Predictor users:

Rating prediction for Good Bye 2017 wouldn't be as accurate as always, because previous educational round not judged yet, so div2 users that participate in it have unknown rating. I decided to use predicted ratings from educational contest as initial for Good Bye 2017.

===================================================================

Good luck & high rating and Happy New Year!

===================================================================

Предсказание рейтинга для Good Bye 2017 к сожалению будет не таким точным, как обычно, потомучто до сих не проведена финальная проверка последнего educational раунда. Таким образом у участников educational раунда (из второго дивизиона) не известный рейтинг на момент начала Good Bye 2017. Я решил, в качестве апроксимации начального рейтинга перед сегодняшним контестом взять предсказания по educational раунду. Надеюсь, что расхождение будет не очень значительным:)

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

If the sys test process is programmed to start automatically right after the educational round end, don't forget to disable it, or we will be getting 2 hours queue.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Can i cancel registration?

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Is 2.5 hours enough for 8 problems to solve? Thanks!

»
9 years ago, hide # |
 
Vote: I like it -10 Vote: I do not like it

I lost a girl recently ,so I hope I could do better in codeforces....

»
9 years ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

I'm anticipating a lot of math problems. Everytime Lewin organizes a round, there are plenty of beautiful math problems that I always fail on :(

»
9 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

But... it's not even december 31st..

»
9 years ago, hide # |
 
Vote: I like it +13 Vote: I do not like it

Hope for shorter statements :)

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Happy new year !!! In this 2018 I hope that we will be better than last year, and of course I wish good luck to the all contests in 2018.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

After a long time contest=(Div1 + Div2)! :p

»
9 years ago, hide # |
 
Vote: I like it +131 Vote: I do not like it

CF new winner EvenImage !!!

»
9 years ago, hide # |
 
Vote: I like it +12 Vote: I do not like it

Goodbye Div 1 Contest. :|

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

are we going to see first 10k participation :D

»
9 years ago, hide # |
 
Vote: I like it +83 Vote: I do not like it

Waiting for around 15 minutes to post this. Have Fun

»
9 years ago, hide # |
 
Vote: I like it +32 Vote: I do not like it

Goodbye Candidate Master. Hello Expert. :P

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

in queue :| right before contest :|

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +61 Vote: I do not like it

Will there be a delay to reach 10K?

UPD: as expected the first 5 mins delay :"D

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Good luck, everyone!

»
9 years ago, hide # |
 
Vote: I like it +36 Vote: I do not like it

It is Delayed to reach 10K :D

»
9 years ago, hide # |
 
Vote: I like it +11 Vote: I do not like it

Have been while to see delays...

»
9 years ago, hide # |
 
Vote: I like it +11 Vote: I do not like it

"you may click the link to enter the contest area"

never been so deceived in my life :(

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Did anyone else get 0:00 on timer and contest not yet started message??

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

What will the rating change base on? My current rating or my rating after edu. round?

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

HOpE there will be no problem like site not available :/

»
9 years ago, hide # |
Rev. 3  
Vote: I like it -6 Vote: I do not like it

Codeforces is slow right now. :(

UPD - Seems fine now :)

»
9 years ago, hide # |
 
Vote: I like it +12 Vote: I do not like it

the server is acting up again

»
9 years ago, hide # |
 
Vote: I like it +18 Vote: I do not like it

dafuq is this contest :(

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +14 Vote: I do not like it

seems like it's DIV 1 + DIV 1.52017

»
9 years ago, hide # |
Rev. 9  
Vote: I like it +111 Vote: I do not like it

I hate this contest so much. First three problems are as easy as it could be, they are just stupid, not for the codeforces, and then just wtf.

I mean, usually people easily make a smooth transition from simple problems to hard problems, what the hell happened to the authors this time? There is even nothing to hack.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +9 Vote: I do not like it

    Third one is easy if you have any idea about geometry, which I don't.

    • »
      »
      »
      9 years ago, hide # ^ |
       
      Vote: I like it 0 Vote: I do not like it

      If you don't know geometry, use a binary search by answer :)

      • »
        »
        »
        »
        9 years ago, hide # ^ |
         
        Vote: I like it 0 Vote: I do not like it

        that gave me 3 TLE's

        • »
          »
          »
          »
          »
          9 years ago, hide # ^ |
          Rev. 2  
          Vote: I like it +3 Vote: I do not like it

          When you do binary search on doubles, you might want to consider stopping after a certain number of steps instead of when left and right are (almost) equal. i.e. do for(int step=0; step<50; ++step) { ... } instead of while(right - left > eps) { ... }. I modified this in your code and "upgraded" it (if you can call it that) from a TL on test 4 to a WA on test 7.

          quick EDIT: I looked over your code a little bit more and fixed this line: return (one * one + two * two) < (twoR * twoR + EPS); to this: return (one * one + two * two) <= (twoR * twoR);

          ... and got accepted. (In general) Don't use eps for comparisons, only for checking equality. So in principle binary search works, you just need to know how to work with doubles :P

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +19 Vote: I do not like it

    You know what to do, do you?

  • »
    »
    9 years ago, hide # ^ |
    Rev. 2  
    Vote: I like it 0 Vote: I do not like it

    Have you read F?

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +1 Vote: I do not like it

The problem provider use Math f**k me.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

If I submit 2 solutions and both clear the pretest will I still face a penalty of 50 points During this contest me second solution which I submitted after 4 min of the first sol my score was approximately 50 less

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +2 Vote: I do not like it

    Resubmission gets you penalty every time except compilation error or wrong answer on sample 1.

    • »
      »
      »
      9 years ago, hide # ^ |
       
      Vote: I like it 0 Vote: I do not like it

      even if both sol are correct and accepted? Thanks

      • »
        »
        »
        »
        9 years ago, hide # ^ |
         
        Vote: I like it 0 Vote: I do not like it

        Yes. Even more: if you got accepted and then WA, your WA will be scored (I'm not sure if that's true if the WA fails pretests, but it definitely is true if both solutions passed the pretests: in that case, your last submission is considered to be your choice).

        • »
          »
          »
          »
          »
          9 years ago, hide # ^ |
           
          Vote: I like it 0 Vote: I do not like it

          ohhh.Tysm as I didn't knew about this as I am new to this platform

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    In the score table, you can see each resubmission is -50. Only the last submission that passes pretests will be judged. Everything else will be ignored.

    So, yes, you still get a penalty.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Yes, you will face a penalty of 50 points, similar thing happened with me.

»
9 years ago, hide # |
 
Vote: I like it -6 Vote: I do not like it

I don't understand why my submission for 2C fails pretest#1 even though it matches the output in the problem statement :S

»
9 years ago, hide # |
 
Vote: I like it +38 Vote: I do not like it

Am I alone who's hating this fucking "Expected number" ? :/

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +4 Vote: I do not like it

    I usually like this kind of problems, though, I suppose, many of contestants never solved this problems, but this time it's something beyond common sense.

»
9 years ago, hide # |
 
Vote: I like it +34 Vote: I do not like it

good bye 2017 && rating

»
9 years ago, hide # |
 
Vote: I like it +103 Vote: I do not like it

What’s up dotorya, I am ko_osaga from South Korea. I’m a huge fan of you. You were 2nd in Facebook Hacker Cup 2017, your team was a Grand Champion at ICPC Daejeon 2017, you and your team continued to amaze Petr for a long time. It is unbelievable. I think your team will be a champion at ICPC WF 2018. I’m doing CP for 4 years and still I’m not like you. I want to improve my skill and be a great competitive programmer like you. How can I be a great competitive programmer like you? What is your training method?? Do you have any secret tips???? Please answer my question. Thanks in advance.

  • »
    »
    9 years ago, hide # ^ |
    Rev. 2  
    Vote: I like it +10 Vote: I do not like it

    (+ I was writing this 15 minutes before the contest ends, and I'm so sad that Petr got first place — no personal feelings, but it's more fun to troll dotorya when he is in first place)

    • »
      »
      »
      9 years ago, hide # ^ |
       
      Vote: I like it +20 Vote: I do not like it

      I have same questions for you :) . How can I be a great competitive programmer like you? What is your training method?? Do you have any secret tips???? Please answer my question. Thanks in advance.

    • »
      »
      »
      9 years ago, hide # ^ |
       
      Vote: I like it +5 Vote: I do not like it

      Yep me too(I have been recently following dotorya and he's awessome). But I was sadder before for that Petr would be losing his place for the silliest reason possible. And actually that last minute manoeuvre by Petr made the contest twice as much fun to watch.

      • »
        »
        »
        »
        9 years ago, hide # ^ |
        Rev. 2  
        Vote: I like it 0 Vote: I do not like it

        I didn't thought that he will lose his first place, but it really happened. Amazing piece of sports :D

        However, I don't know why Petr gained +250 from the Hack. AFAIK He should only gain +200. (3 * 100 — 2 * 50) (UPD : It was fixed somehow)

        • »
          »
          »
          »
          »
          9 years ago, hide # ^ |
           
          Vote: I like it +59 Vote: I do not like it

          The last hack happened 1 second after the end of the contest.

          • »
            »
            »
            »
            »
            »
            9 years ago, hide # ^ |
             
            Vote: I like it 0 Vote: I do not like it

            Yup I thought you should get +3 -2, but somehow it was written like +3 -1 (-1) and the one from 147:02 didn't count. That was what happened when I took screenshot, but it was resolved right after I wrote the reply. Sorry for the confusion :/

          • »
            »
            »
            »
            »
            »
            9 years ago, hide # ^ |
            Rev. 2  
            Vote: I like it +35 Vote: I do not like it

            for Petr even time slows down. and a black hole is created,

»
9 years ago, hide # |
 
Vote: I like it +6 Vote: I do not like it

What is the solution for F?

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

Is F an analysis of various cases ?

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    what is test case 4 of F?!

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    i have a pretty simple greedy.
    Claim1: Answer is a spanning tree in most cases.(I Will describe corner case later)
    Claim2: Green component is connected by itself
    Now its pretty easy to see that after connecting Green with a chain , we need to connect reds and blues between 2 greens in a block with a chain sort of thing(We leave out the biggest gap here) Corner case (instead of connected 2 consecutive greens with a chain and reds and blues with spanning tree , we can instead make a cycle , ie connected green -> red -> red -> ... -> red -> green and green -> blue -> blue -> ... -> blue -> green).

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Yes it is, and it is the worst type of question for a sleepy programmer to pick up in a contest. :/

»
9 years ago, hide # |
Rev. 2  
Vote: I like it 0 Vote: I do not like it

Hack for C.

5 2
1 10 7 3 6

Output: 2.000000000 2.000000000 4.645751311 5.464101615 8.518734657

»
9 years ago, hide # |
Rev. 3  
Vote: I like it -39 Vote: I do not like it

edit since I've calmed down slightly

If you are going to write problems, PLEASE make sure that if you find the optimal solution, you will get the problem right instead of having to fiddle around forever with random implementation details. There is no purpose in having contestants sit around trying to reimplement standard data types or come up with increasingly "creative" (re: sketchy) ways to get around overflow or try to shave off constant factors, at least in a purportedly algorithms-based contest. Whether you implement this by increasing the time limit or setting the problems limits to something more reasonable (k=1000 is just unnecessary considering the normal Python implementation runs fine with k=500 or so) doesn't really matter, but shifting the focus away from algorithms and onto constant time improvements really defeats the purpose.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +21 Vote: I do not like it

    I don't believe the problem is intended for you to implement fractions, but work with modular arithmetic by calculating the modular inverses by means of FLT or Euclidean algorithm.

    • »
      »
      »
      9 years ago, hide # ^ |
       
      Vote: I like it -16 Vote: I do not like it

      Well, official solution reimplements fraction data type, so I think this was intended. Of course modular inverses are a very easy solved problem that is used only at the end.

      • »
        »
        »
        »
        9 years ago, hide # ^ |
        Rev. 2  
        Vote: I like it +5 Vote: I do not like it

        I read the solutions, and it has no mention of implementing fraction data type. What I mean by working with modular inverses is you don't ever need to work with fractions at all. Instead of a / b use and you obtain the same result, not just the last calculation. With the number of prime factors you can include as part of your input, overflow is bound to happen.

        See for yourself : 33784912

        • »
          »
          »
          »
          »
          9 years ago, hide # ^ |
           
          Vote: I like it -19 Vote: I do not like it

          Ok, it is possible that I'm misreading the official solution and there is some graceful way of handling overflow. This isn't really my main point though; I don't care much about whether overflow exists supposing there is a simple way of dealing with it. My main concern/complaint is that doing this problem in Python is evidently practically impossible even with the optimal solution (there are no accepted solutions in Python), and considering that this could have been remedied with a trivial tweak to the limits (that wouldn't allow solutions of suboptimal time complexity), it seems that this was done intentionally which I cannot understand the purpose of.

          • »
            »
            »
            »
            »
            »
            9 years ago, hide # ^ |
            Rev. 2  
            Vote: I like it +5 Vote: I do not like it

            Well then I don't understand you. The reason your Python solution probably failed is because you allowed the size of your factors to become so large they consume too much time per multiplication, addition, etc. You obviously should have evaluated the time and realised this solution is not practical. I was unaware Python does not support modulo calculations (sarcasm).

            • »
              »
              »
              »
              »
              »
              »
              9 years ago, hide # ^ |
              Rev. 2  
              Vote: I like it -14 Vote: I do not like it

              I suppose we will have to agree to disagree then -- in my view the implementation is essentially just a means of proving one's solution, and choosing limits so that implementations in some languages are essentially not possible (at least without a lot of constant time twiddling) seems to me to place the focus off of problem solving, which in theory is what these contests aim at. But as I said, I can understand that others will have different interests and will prefer these types of constant-optimization challenges. Of course thanks for your opinion.

              • »
                »
                »
                »
                »
                »
                »
                »
                9 years ago, hide # ^ |
                 
                Vote: I like it +9 Vote: I do not like it

                So to summarise your point, you believe big-Num multiplication is "constant time twiddling"? Because I doubt your solution fails by only a constant factor.

  • »
    »
    9 years ago, hide # ^ |
    Rev. 2  
    Vote: I like it -18 Vote: I do not like it

    I see now official solution is to give wrong fraction but one which gives same final answer. Ok, I guess it is possible to figure out this "trick" during contest, but IMO solving the problem should be the important part of the problem and if limits are chosen so that the official solution cannot be implemented (basically word for word) in Python then something is fundamentally wrong with the writing approach. Of course I understand that everyone's taste is different and some people prefer to optimize constant factors, but IMO this isn't really what these kinds of contests are for.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +1 Vote: I do not like it

    "come up with increasingly "creative" (re: sketchy) ways to get around overflow" : that's basically half of number-theoretic problems.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

how to solve D?

»
9 years ago, hide # |
 
Vote: I like it +16 Vote: I do not like it

So I was reading problem E and I wondered if the intended solution used any kind of knowledge on algebraic structures, did anyone solve it like that?

»
9 years ago, hide # |
 
Vote: I like it +4 Vote: I do not like it

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

How to solve H ? I have a idea based on minimum clique partition in the graph of AND-components of size

Unable to parse markup [type=CF_TEX]

, with edges corresponding to XOR constraints, but couldn't debug it in time.
»
9 years ago, hide # |
Rev. 2  
Vote: I like it +14 Vote: I do not like it

What is an 'unsuccessful open hacking attempt', showing for Petr in the scoreboard?

edit: now it doesn't show anymore

»
9 years ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

How to Solve D ?

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +6 Vote: I do not like it

    Notice that every time you place 'b' amount of subsequences "ab" increases by the current number of 'a' in the string. So dp[x][y] — answer if we have x 'a' in our string and y subsequences 'ab'. If x = 0, y = 0 then dp[x][y] = dp[x + 1][y] ('b' in the beginning of the string don't influence on the answer and we will place 'a' in one moment. The thing is that we can place many of 'a'. If x > k, then we will finish our process after first symbol 'b' will appear. So in this case we can add to dp[x][y] x + y(it will be in answer) and then add the expected amount of 'a' untill we will place 'b'. Denote the last one by E, so find it from the equation: .

»
9 years ago, hide # |
Rev. 2  
Vote: I like it 0 Vote: I do not like it

The series for G seemed very 'fractal like'. How do you solve it?

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

How to solve D,E,F?

»
9 years ago, hide # |
 
Vote: I like it +34 Vote: I do not like it

goodbye rating 2017

»
9 years ago, hide # |
Rev. 2  
Vote: I like it +3 Vote: I do not like it

I made 9 successful hacks during the contest. Let me explain what I found...

For problem B, some implementations don't consider the last step. An example of hack is...

2 2

SE

##

0

For problem C, some consider that the intersection will occur between the droping disk and the disk with max index (and, a disk with max y). Examples to both of them...

3 10

10 30 19

5 10

10 10 50 49 30

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Happy New Year!

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

This Year Gift From CF " No one will lose rating from this contest " (Please) :P

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

double system-test!

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

first of all how the expected value for the 1st example problem of D is 2, as the expected value is 1/4(ab) + 1/8(bab) + 1/16(bbab) +.... which is 1/2. so how it came to be 2 ?

»
9 years ago, hide # |
 
Vote: I like it +7 Vote: I do not like it

Time to back div2. A_A

»
9 years ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

maths too hard~~

»
9 years ago, hide # |
 
Vote: I like it +26 Vote: I do not like it

Codeforces aesthetics

»
9 years ago, hide # |
 
Vote: I like it +2 Vote: I do not like it

Nice upvote :D

»
9 years ago, hide # |
 
Vote: I like it +54 Vote: I do not like it
»
9 years ago, hide # |
 
Vote: I like it +27 Vote: I do not like it

»
9 years ago, hide # |
 
Vote: I like it +118 Vote: I do not like it

Did anyone see anything like this when trying to hack a solution?

When will MikeMirzayanov finally understand that Flash's place is in a museum, not on a live website?

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

i cant hack any solutions. i have flash player enabled and i locked the problem.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

What's wrong with trigonometry for C? My trig solution failed systests.

Is it because c++ trig functions break on obtuse angle? (this is my guess from playing around with the code, not sure though)

»
9 years ago, hide # |
 
Vote: I like it +5 Vote: I do not like it

My solution for problem C failed test case 7: "wrong output format Expected double, but "nan" found" . What went wrong here ? My Solution: http://codeforces.me/contest/908/submission/33782812 Thanks.

»
9 years ago, hide # |
 
Vote: I like it +12 Vote: I do not like it

Thanks C++ for x + NaN > y being always false.

In task C, I didn't even consider that sqr(2r) may be larger than sqr(x[i] - x[j]). I was just mislead by a picture, that I drew, with two circles touching each other. I identified 2r as hypotenuse length and |x[i] - x[j]| as cathetus length, and c'mon, how a hypotenuse can be shorter than a cathetus? But when |x[i] - x[j]| > 2r, these values clearly have nothing to do with a right triangle sides, so (without realizing this) I got a negative "cathetus length" under the square root in my solution. Lucky me, NaN arithmetics works in C++ as needed to make my code work properly.

»
9 years ago, hide # |
 
Vote: I like it -6 Vote: I do not like it

does the graph have to be connected in F? or does it only need to be connected from the point of view of red / blue?.

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Can someone explain why the C++17 compiler made my code TLE while C++14 was accepted? During the contest I did not notice that my default compiler was changed to C++17 and simply thought my solution was too slow, but after I resubmitted the same code after the contest and it was AC...

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +8 Vote: I do not like it

    It's strange to see "GNU C++17 Diagnostics" shouldn't it be "GNU C++17" ?

»
9 years ago, hide # |
Rev. 8  
Vote: I like it -11 Vote: I do not like it

EDIT: Found the conceptual error in my code. It would fail systest anyways. Thank you for the help :)

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +1 Vote: I do not like it

    On my accepted solution, the answer on that test case is:

    4.0000000000 4.0000000000 11.4161984871

    Whereas the answer using your code is:

    4.0000000000 4.0000000000 10.2449979984

    I haven't read your code thoroughly (it's a bit messy :P) but from what I can see, when checking what disk touches the one you put in, you only consider the disk with the highest y, but there might be a disk with lower (or equal) y that causes the intersection point with your new disk to be higher :)

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +1 Vote: I do not like it

    Got this from AC code:

    4.000000 4.000000 11.416198

    your code gives 10.x at last position.

    Anyway, you have one of the same bug I had: Don't check max_y. Its possible that even lower y stops the ball at higher position.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Thank you, all of you. I got the bug. I am grateful :)

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

What's wrong with my approach ? Getting WA on case 7. Please help. http://codeforces.me/contest/908/submission/33785962

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    You are calculating the position of the center with respect to the upper most intersecting disk. But it's can be more lower for any other disk at lower position if the touching point is upper than that of the upper disk.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    You should calculate the y coordinate of center for every touching disk and keep the maximum of them.

»
9 years ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

Happy new year Codeforces :D

»
9 years ago, hide # |
 
Vote: I like it +7 Vote: I do not like it

Hello:

Why were all successful hacks not added to the system test data?

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    I think in general, only suspicious hacks get added (i.e. ones that fail a solution that would have otherwise passed systests).

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Hopefully Codeforces simply rejudges all solutions with hack tests and does not make it unrated :/

Happy New Year everyone!

»
9 years ago, hide # |
 
Vote: I like it +8 Vote: I do not like it

I think it's the last chance to drop my rating...

»
9 years ago, hide # |
 
Vote: I like it +4 Vote: I do not like it

Even though the contest is over, why has not the new rate been calculated yet ?

»
9 years ago, hide # |
Rev. 2  
Vote: I like it 0 Vote: I do not like it

Can anyone have a look at my solution for B and point out the mistake?

Link

Thank you in advance.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    Hint: What happens if you reach the destination exactly after processing the last instruction?

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    On a quick glance, it seems like when following the instructions, you first make the checks and then take the step, but you should first take the step and then make the checks (otherwise you miss the checks for the last step).

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

In problem A, should I have tried to hack this submission? 33778092

The string size limit is 50 and the char array have size 50. It loop until reach a '\0' character... It have failed sometimes in my computer.

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it 0 Vote: I do not like it

    In principle, this code produces undefined behavior which might mean that sometimes it will work and otherwise will not.

    In practice, the array a is allocated on the stack since it is declared locally. a[49] is the last element of a, a[50] references the first address on the stack after the space allocated to a. That element might sometimes be \0, sometimes not, but it is very likely that there will be SOME null byte somewhere on the stack after the space allocated to a.

    • »
      »
      »
      9 years ago, hide # ^ |
      Rev. 2  
      Vote: I like it 0 Vote: I do not like it

      I think you're wrong. The idea here is that on the stack after a[49] comes variable c, which has the first byte always 0 (because of the constrains) and the loop stops as expected.

      • »
        »
        »
        »
        9 years ago, hide # ^ |
        Rev. 2  
        Vote: I like it +3 Vote: I do not like it

        (On most systems) things on the stack are pushed towards lower addresses. In other words if you have int a; int b; declared locally, b will be at a LOWER address (even though a is pushed first).

        To test this, you can add this line printf("%08X %08X %08X\n", &a, &c, &a[50]); after the variable declarations and you'll see something like 00B5FA04 00B5F9F8 00B5FA36. As you can see, the address of c is lower than the address of a (and obviously different than the address of a[50]). You can test this with both VS and GCC.

        EDIT: P.S. I've tested the code and on my machine, with VS2017, about 1 in 5 times it will give Wrong Answer. As I've said, the program will keep reading bytes from the stack until it will eventually read a null byte, but in the meantime it might also read other bytes and those other bytes might contain vowels or odd digits (therefore wrongly increasing the counter). Here is an example of this happening (the program prints 1 when the answer should be 0).

»
9 years ago, hide # |
 
Vote: I like it +27 Vote: I do not like it

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Why the hell is Educational round System Tsting So

  • »
    »
    9 years ago, hide # ^ |
     
    Vote: I like it +3 Vote: I do not like it

    As every hack will be appended into the system tests, in some cases/problems the judging process for a submission can be freaking long.

    (As I've seen, there are 140 test cases in total for problem A of this Educational. Not really paying attention of others, but they are surely pretty large as well.)

»
9 years ago, hide # |
 
Vote: I like it +1 Vote: I do not like it

When will the ratings be updated?

»
9 years ago, hide # |
 
Vote: I like it +9 Vote: I do not like it

Finally, blue. :-D

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

A new year with a new color <3'

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Goodbye 2017. So close to the purple dream, but I believe I'll get it next year.

To anyone reading this: wish you have a lot of "Accepted"s in the new year ;)

»
9 years ago, hide # |
 
Vote: I like it +8 Vote: I do not like it

OMG I became 1599... Not expert T_T

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Saying goodbye to 2017 is as hard as solving problems of "Good Bye 2017".

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Nice contest! Anyway, the problem statements have nothing to do with New Year.. :P

»
9 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

MikeMirzayanov it seems the rating changes for this round don't appear in the RATING page ,for example Petr's rating changed from 3173 to 3298 ,yet it still shows 3173 in the rating page ,same with me and everyone I know/follow

»
9 years ago, hide # |
 
Vote: I like it +10 Vote: I do not like it

Liked the Problem D. Thanks Lewin

»
9 years ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

-555 in task D is Good Bye 2017