FieryPhoenix's blog

By FieryPhoenix, 4 years ago, In English

Hi Codeforces!

I’m thrilled to invite you to Codeforces Round 638 (Div. 2), which will take place on 01.05.2020 17:35 (Московское время). It's rated!

There will be 6 problems, and you will have 2.5 hours to solve them. All the problems are written and prepared by me.

Huge thank you to everyone who made this round possible:

I hope everyone will enjoy the problems! I have tried to make short statements and strong pretests. Hopefully this contest will be even better than my previous one :)

UPD: Thanks also to darnley for proofreading statements and suggestions!

UPD: The scoring distribution is standard: 500 — 1000 — 1500 — 2000 — 2500 — 3000

UPD: Editorial is here

UPD: Congratulations to the winners! I hope most of you enjoyed the round. If you have any questions, feel free to ask in the comments.

Overall Winners:

  1. dreamoon_love_AA

  2. KrK

  3. peti1234

  4. antontrygubO_o

  5. I_love_Tanya_Romanova

Div 2. Winners:

  1. Fecto_Elfilis

  2. czyarl

  3. NishimiyaShouko

  4. PureVessel

  5. Neraxis

  • Vote: I like it
  • +1358
  • Vote: I do not like it

| Write comment?
»
4 years ago, # |
Rev. 2   Vote: I like it +27 Vote: I do not like it

Thanks for your hard work making the contest,

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

Thank you Fiery for taking the time to write a contest for us. I am sure it will be a stellar contest since it was written by the god Fiery himself.

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

It is going to be good contest! GL & HF for everyone!

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

Ahh, more ans more contests!! I like it..

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

OMG BENQ TESTED A ROUND :O

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

codeforces is saving me in this quarantine period.

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

short statements and strong pretest very happy to see this

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

    Agree, always loved to solve problems with short statements

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

Looking forward to some FieryProblems with FieryPretests !!

»
4 years ago, # |
Rev. 3   Vote: I like it -136 Vote: I do not like it

[Deleted]

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

    Except yours.

    • »
      »
      »
      4 years ago, # ^ |
      Rev. 3   Vote: I like it -123 Vote: I do not like it

      :((((((

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

        When people put "[Deleted]" on their comments, that just makes me want to downvote them more. I'm still gonna see the comment, but now I have to spend time pressing previous revision.

        • »
          »
          »
          »
          »
          4 years ago, # ^ |
            Vote: I like it -10 Vote: I do not like it

          How to do that? Where is the option / button for that?

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

            On top of every edited comment, left of the upvote button.

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

            If a comment has been edited, there would be ← Rev. 2 to the left of the upvote/downvote count (or a higher number if it's been edited multiple times).

            Click on that left arrow to go to the previous revision.

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

            I seriously don't understand why my above comment deserves downvotes I just thanked a person It's not like I care about my contribution , but I would like to know what it is that i said which is troubling people? [Edit: I posted this when there were 21 downvotes]

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

          Oky i wont edit them like that anymore, seems everyone has the same thoughts as you. In my opinion when someone deletes his/her comment, then it means he is shameful of what he said or he thinks his comment is nor fun neither helpful.

      • »
        »
        »
        »
        4 years ago, # ^ |
          Vote: I like it -11 Vote: I do not like it

        [Deleted]

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

        WTF -125 0-0

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

I'm Waiting eagerly to participate in this contest in the quarantine period. Hope it will create an excitement a bit more

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

hope this will be wonderful

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

Thanks to Codeforces for saving me from my boring time,which gives me more opportunities to get in touch with algorithm knowledge and make lots of like-minded friends.Thanks for your hard work to make this meaningful contest.
I'm really looking forward to this contest!! Hope everyone have a good performance. Good Luck ! :)

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

Can someone share his old contest's link ?

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

thanks FieryPhoenix... thanks codeforces... the only friend i can visit yet *_^ Always at the peak :))

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

I'm glad for the short statement. I hope the authors of future contests also think like you.

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

It will be great if there is no links in the statements:) -> it always takes me a long time to open them.:(

»
4 years ago, # |
Rev. 2   Vote: I like it +12 Vote: I do not like it

Thank you to make sure exact "problem number and contest duration" before 2 days .

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

Tight! Tight! Tight! Yeah!!!

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

Thank you and Codeforces team for making our quarantine enjoyable and productive.

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

2cob0e

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

Thanks for it "** I have tried to make short statements and strong pretests**"

»
4 years ago, # |
Rev. 2   Vote: I like it +144 Vote: I do not like it

Announcement: ...You, for participating!

Everyone :

ZQdv9UQ

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

""I have tried to make short statements and strong pretests."" ..Happy to see this..i think there have not any confused word like "simultaneously" (in the previous contest) ..GL everyone.

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

I appreciate your efforts for personally writing this post yoursef :)

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

Thanks a lot. But please make the problem statements clear enough and straightforward. Best Wishes <3

»
4 years ago, # |
  Vote: I like it +54 Vote: I do not like it
"You, for participating!"

It felt so good to hear this.

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

i have a good feel about the contest ,I feel this contest have a nice ideas and problems.

»
4 years ago, # |
  Vote: I like it +54 Vote: I do not like it
»
4 years ago, # |
  Vote: I like it -14 Vote: I do not like it

Hope no "simultaneously" to meant "at anytime".

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

Hey!

I'm sorry if this has been asked before — but I'm just curious about why rounds are becoming longer on average? There seem to be a few rounds these days which are either 5 questions in 2 hours or 6 questions in 2 hours and 30 minutes. A short while back, rounds seemed to be 6 questions in 2 hours on average.

Are authors and coordinators looking to make rounds harder, or maybe more implementation based? Or is this to account for more participants in some way?

Thanks!

»
4 years ago, # |
Rev. 6   Vote: I like it 0 Vote: I do not like it

It feels like I'm participating in the contest after ages

»
4 years ago, # |
Rev. 2   Vote: I like it -113 Vote: I do not like it

Nothing matters anymore

  • »
    »
    4 years ago, # ^ |
      Vote: I like it -8 Vote: I do not like it

    make codeforces, not coronaforces

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

I want to be Master !!! rp++

»
4 years ago, # |
Rev. 3   Vote: I like it -92 Vote: I do not like it

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

    Please stop re-posting memes from last contests. Get something new man! We're bored of this.

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

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

Hi, I am new to this platform and would like to know more about the contest. Details such as — what parameters will affect my ratings?

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

    For your site rating, the system is ELO based. For the rating for any particular contest, the problems are worth different amounts, and you also get less points for a problem as time goes on.

    You can look up the FAQ.

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

Very happy to hear "short statements and strong pretests". This contest is how all contests should be. Also, one very very good thing is this guy thanks the participants , a new start on Codeforces . This practice should be carried on.

»
4 years ago, # |
  Vote: I like it -7 Vote: I do not like it

Scoring distribution please. :)

  • »
    »
    4 years ago, # ^ |
      Vote: I like it -7 Vote: I do not like it

    Score distribution generally ppublish just before the contest start

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

    It's up now :)

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

      Its great to see score distribution one day before the contest.

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

Hope for a balanced contest (hope so, because of balance score distribution)

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

As someone who tested this round, I can guarantee that FieryPhoenix's English is very good, and there are no major grammatical mistakes in the task statements!

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

    I'm curious. Given the situation, you would have found "major grammatical mistakes in the task statements". What would you have posted here instead?

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

      As a tester I would have fixed them before the contest even began by pointing them out to the contest writer :)

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

    I would be very shocked if his English was bad, considering he is in United States.

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

  • »
    »
    4 years ago, # ^ |
      Vote: I like it -8 Vote: I do not like it

    Maybe you should hope that it does come in this contest itself! :/

»
4 years ago, # |
  Vote: I like it -66 Vote: I do not like it

Can u make it 30 or 60 minutes earlier?

  • »
    »
    4 years ago, # ^ |
      Vote: I like it -37 Vote: I do not like it

    When you ask for an earlier contest and all you got was downvotes

»
4 years ago, # |
  Vote: I like it -28 Vote: I do not like it

Do anybody here like long story type statements? I enjoy them, when the story has a character. The story of the character of one problem is related to the previous one.

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

    I don't mind a story and sometimes I enjoy reading them. All I'm asking for, though, is clarity of the task. I think it is better for short contests like codeforces ones (2 to 2.5 hours) to have brief statements, as not every participant is equally educated to English.

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

    Go read novel. Dont waste time here.

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

Hopes to see some new problems starting with COWs on codeforces!

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

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

Contest after 5 days. So much excited. Good Luck everyone. <3

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

Want to be pupil for the 1st time after so many struggle. Just 14 need..GL & HF .

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

Contest and Ramadan ... Both are enjoyable...

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

Hope this contest can be nice! Good luck for everyone!!

»
4 years ago, # |
Rev. 2   Vote: I like it +22 Vote: I do not like it

500 — 1000 — 1500 — 2000 — 2500 — 3000
After a long time, the score distribution is an arithmetic sequence! Really looking forward to this round!

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

    Finally, well-balanced round

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

      I cannot disagree more with this statement. Div2B was the hardest Div2B I have seen in a while.

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

        I agree it was a bit harder than usual but I really liked the actual problem.

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

        at the same time,it's the easiest div2D i ever met

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

Oh, It's May Day Contest.

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

    and my rating sends mayday signal

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

i wish i would become specialist today. but not sure about it. need rank under 4500 or mostly i do bad in div2 haha.

»
4 years ago, # |
Rev. 2   Vote: I like it -11 Vote: I do not like it

Almost 20k participants... It's amazing!!

Upd. 20k+..sensationally

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

For the first time, I noticed in contest announcement to include You, for participating in thanks giving list. Liked it. You forgot to include yourself in the list. Thanks for your efforts to make the round!

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

here scoring distribution is standard, does that mean there is no difference between the guy who solves faster than other. And how does the ranking is decided? is there any penalty

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

    As time passes, each problem is worth less points. So there is a difference between the guy who solves faster than the other.

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

Rip rating

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

How to solve C and D?

  • »
    »
    4 years ago, # ^ |
    Rev. 3   Vote: I like it +14 Vote: I do not like it
    D
    • »
      »
      »
      4 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Sorry, I feel like, Yes, did all of the above. And then, what should I print as ans?

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

    For c i used some observations. first sort the given string s. then try to distribute initial k characters for i = 0 to k-1. the remaining string rem = s[k:n] if rem contains more than one distinct char then it is better to add this whole rem to k-1 th string.Then ans = s[k-1] + rem

    if rem only contains only one distinct char(like aaa , bbbbb) distribute those n-k characters equally , (n-k)%k will be remained after that. if (n-k)%k !=0 we need to add an extra character to ans then ans = s[k-1] + rem[0] * ((n-k)/k + ( (n-k)%k == 0 ? 0 :1)) )

    note : "a" *3 = "aaa"

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

what was the TestCase 10 in E

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

Great round and great problems! Your contests are brilliant! I solved AD. I feel D and C should've been swapped. D felt a lot easier tbh. I found D easier than B, which I wasn't able to solve (and wasted more than 40 mins on) :( I was clueless on C after pondering and drawing stuff for 20-ish minutes. Read D, and happened to solve it in about 15-20 mins.

Also, does anyone know how to hack solutions? I locked my problems at around 2:20 and tried viewing other solutions for D, however, none of them loaded. Is it just my internet or servers being slow or am I doing something wrong?

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

    Acc to me C was easy. You just need to know "aac" is greater than "aaaac" and bingo :)

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

Video Editorials for today's C and D

C

D

Enjoy watching!

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

How do you do C? I tried doing casework but miserably failed )):

D was pretty easy for placement though (for those who are more math-minded)

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

    How did you did B it was a lot difficult

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

    For c i used some observations. first sort the given string s. then try to distribute initial k characters for i = 0 to k-1. the remaining string rem = s[k:n] if rem contains more than one distinct char then it is better to add this whole rem to k-1 th string.Then ans = s[k-1] + rem

    if rem only contains only one distinct char(like aaa , bbbbb) distribute those n-k characters equally , (n-k)%k will be remained after that. if (n-k)%k !=0 we need to add an extra character to ans then ans = s[k-1] + rem[0] * ((n-k)/k + ( (n-k)%k == 0 ? 0 :1)) )

    note : "a" *3 = "aaa"

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

Why so much tight time limits for problem E. My code kept giving TLE on test case 33.

  • »
    »
    4 years ago, # ^ |
    Rev. 2   Vote: I like it +16 Vote: I do not like it

    I guess they intended to optimise max computation :/

    UPD

    Wait, what? 78729467 78794202 I thought that n*k was the intended solution when I wrote this comment. But yes, indeed harsh time limit.

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

    I guess you forgot to update DP and it calculates each of them too many times.

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

      I am updating the dp, notice that I have used ll &ans=dp[ind][red] and not ll ans=dp[ind][red].

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

        Oh right. My solution is very close to yours but not with recursive functions but with true DP.

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

    All of our solutions ran very fast, but I didn't expect a recursive approach. Sorry about that.

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

      So according to your estimate, recursive approach is how much slower than iterative one? this will help me in future.

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

        In general, recursion has a higher constant factor than iteration.

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

        There are some cases when recursive works faster since it calculates fewer states. Anyway, I think the main problem is long long arrays with many modulo operations

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

    Why would you use long longs everywhere and not submit in C++64? Long long stuff run a lot faster in C++64.

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

      I didn't notice that there is a C++ 64 also. I am changing my default to C++64 immediately. thanks for pointing out!

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

    I think your problem are the multiple divisions and modulo operations over k. Since you are keeping red and blue to be modulo k, one easy (and actually faster) way to do this is using an if: if (something >= k) something -= k, ans++; I'm doing exactly what you are doing (actually added a second loop over the blue ones just to be sure) and still passing with the recursive approach.

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

Not sure what I am doing wrong, but my rating is going down rapidly. Nice problems anyway, thanks for that.

»
4 years ago, # |
Rev. 2   Vote: I like it +32 Vote: I do not like it

WOW Nice problems man, specially E and F, both were very tricky and interesting, C was too tricky in my opinion but still it was very nice.

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

Am I the only one who felt D was easier than C? lol

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

    I wasn't even able to solve C but I solved D after around 20 mins of reading it :(

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

      Yeah, me too lol. D was more like a math question that I've happened to solve in the past. Speedforced it in under 20 mins.

  • »
    »
    4 years ago, # ^ |
    Rev. 3   Vote: I like it +7 Vote: I do not like it

    +1

    Problem C was more complex to write code

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

Great problem!

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

Problem B was tough, I could not debug C on time. Nice contest.

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

Excellent contest FieryPhoenix! Problem D was especially unique and creative. Enjoyed :)

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

Solved D for the first time in a contest and in the last 30 sec, coudn't be happier :')

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

It was the toughest B for me

  • »
    »
    4 years ago, # ^ |
    Rev. 2   Vote: I like it +6 Vote: I do not like it

    All you have to do in problem B is that check if total number of different numbers in array is less than or equal to k if this inequality holds means answer exist and take k numbers from array(include each number atleast once) and print them repeatedly n times .

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

Was I the only one who felt it was most difficult B ever and toughest C to implement?

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

    C was a ton of casework, but if you write out all the cases, then the code is actually not too bad. https://codeforces.com/contest/1348/submission/78683019

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

      nice implementation.thanks for sharing! Good takeaways for me!

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

      You can get away with just 3 cases.

      First sort the string.

      Case 1: The bottom K letters are not all the same. Then the answer is simply the K-th letter from the bottom. Example:s="aabcccdddd", K=3 => answer is "b".

      Case 2: The bottom K letters are all the same, but the rest of the letters aren't. Then the answer is a single copy of the bottom letter, followed by the entire top N-K letters. Example: s="aaabcccdddd", K=3 => answer is "abcccdddd".

      Case 3: The bottom K letters are all the same, and the top N-K letters are all the same. Then the answer is a single copy of the bottom letter, followed by (N-1)/K copies of the top letter. Example: s="aaabbbbbbbb", K=3 => answer is "abbb".

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

Is ans for $$$D$$$ is highest bit set in $$$n$$$

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

    This is what I had:

    int days = Long.numberOfTrailingZeros(Long.highestOneBit(n));

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

      How to construct the answer

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

        What I did is have sum = 1, and count = 1. Important thing to notice is that you can only increase count from 0 to count. Greedily choose highest count you can without going over the limit N across the remaining days which can be calculated with binary search or a simple formula:

        long here = Math.min(count, (n — sum) / (days — i) — count);

        Then it is easy as count += here sum += count

        Then print out here for the current day.

        Do this for every i from 0 to days — 1

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

Earlier round of the same setter FieryPheonix was better than this round Round 621

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

Superfast Editorial thanks

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

I wish the pretests were strong. I was able to solve A,B,C for the first time in Div 2. Thanks for the amazing contest.

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

What is test case 2 of problem C??

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

Great contest,,short problem statements that were easy to understand..

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

.

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

I made so many silly mistakes, and it caused me a lot of penalties, it is not happening the first time, can anyone plz suggest me some way or something to reduce these mistakes

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

Could you please help me why I got TLE in problem C

my submission:: https://codeforces.com/contest/1348/submission/78744306

»
4 years ago, # |
Rev. 3   Vote: I like it 0 Vote: I do not like it

.

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

Awesome contest..LOVED D....Tricky E...took a lot of time figuring out that it was actually a dp question but it was too late... :-(

»
4 years ago, # |
  Vote: I like it -35 Vote: I do not like it

This was literally the shittiest contest I ever participated in. Such types of problems are not expected to come in contests NO algorithms ONLY if-else based problems which are of no use at all.

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

    Those if else case works are important for logic building. You can't be better by knowing only algorithms without case works.

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

    Algorithms are tools,which help us solve problems.

    Logic is the real thing that every contest should have.

    What will you, and eventually,everyone say if the next contest is Algorithm-only, logicless?

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

      So you mean algorithm based problems are illogical ??

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

        Algorithms-only:If you meet these Algorithms-only Problems, you'll immediately know which algorithm to use.(Sorry, I should declare that)

        Yes, they aren't absolutely illogical, but they only require a little logic

        They should be used as upsolving problems, instead of contest problems.

        UPD: I know that you didn't perform well in this contest. It doesn't matter. Everyone, including me, had some bad performance in the past.Try to perform well next time. If you are not good at logic-thinking, just practice. Practice makes perfect

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

    I feel you brother, bad results are disapointing. But at least you solved B. Welcome back to green!

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

    How could you solve problems D-E-F with if-else based solutions?

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

    Logical,Mathematical,DS and algorithmic questions are the essence of competitive coding.

    Just because there was no DP, graphs or other known algorithmic questions in the first 4 doesn't mean its bad.

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

I really appreciate that you used BABA in your examples, and also using Phoenix(i know its related to your name) reminds me CSGO's Shattered Web Operation, so i felt at home when solving the problems :D, thank you.

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

My greedy solution in E got AC. Most probably it shouldn't pass but I'm not able to break it.

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

Why does using Priority queue gives TLE on test case 32 in problem C ? isn't it O(nlogn) which should pass ?

Link to Submission

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

Systests are pretty fast this time.It took less than 45 mins :D

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

**This is my solution for A **78678522

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

Everything was perfect in this contest! Thank you!

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

editorial is out at super fast speed :) nice

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

Java or CPP?

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

In problem C why this code gives TLE on test 8? 78747924

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

What is the meaning of this "checker log : wrong answer Unexpected EOF in the participants output" ? I am getting this in TC2 for problem C.
My submission : Here

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

    Means the validator/checker is expecting more lines(i.e. more test cases or more data, whatever) but your input/output doesn't have any more.

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

      Yes thank you very much.
      I used return in testcases instead of continue, I just realized that(T_T).

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

same code

78704677 compiler: GNU C++17 verdict: WA

78705346 compiler: GNU C++17 (64) verdict: AC

But why??

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

    I too wanna know why this happens, last contest i saw someone shared solution that got AC in g++17(64) and tle in g++17.

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

Editorial published so fast.. Thanks.

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

Did the edge between divisions change? I didn't see participants with rating 1900-2100 in official standings of Div2 round before.

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

    when div.1 and div.2 both round happens then only 1900-2100 rated participants belongs to div.1 .

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

    In Div2 only contests (even Educational Rounds actually) are rated for Candidate Masters. When it is a Div2+Div1 contest, then Div1 is rated for Candidate Masters.

»
4 years ago, # |
Rev. 2   Vote: I like it +6 Vote: I do not like it

I have a problem in the judge of my submission to problem C:

This is my submission inside the contest:

https://codeforces.com/contest/1348/submission/78716961

It gives me TLE in test case 25

After the contest I try to copy and paste the code and submit it again here

https://codeforces.com/contest/1348/submission/78751136

It got accepted that mean it should be accepted in the contest too

What is the problem of this?

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

    It sometimes happens that when you run your code multiple times, it takes different times to run.

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

    There are so many submissions on system test stage, the server have lower performance than normal case. And you code runs 1996ms, it's too close 2000Ms. So your code get TLE on systen test stage.

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

      I also try it here:

      78753797

      78753769

      78753708

      and still got accepted how could I ask for rejudge ?

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

        I'm sorry to say that i think you will get TLE again on rejuding stage. And it almost impossible rejudge the contest again!

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

    I mean 1996 ms for a time limit of 2000ms is goddamn close

»
4 years ago, # |
  Vote: I like it -28 Vote: I do not like it

I've just recived this message from System

Внимание!

Ваше решение 78721802 по задаче 1348A значительным образом совпадает с решениями других участников и находится в группе одинаковых решений try11/78721329, Hadiayoub7/78721802. Такое совпадение является явным нарушением правил. Отметим, что непреднамеренное утечка тоже является нарушением. Например, не следует пользоваться ideone.com с настройками по умолчанию (публичным доступом к вашему коду). Если вы имеете неоспоримые доказательства, что совпадение произошло по причине использования общего источника, опубликованного до соревнования, то напишите комментарий к посту о раунде со всеми деталями. Подробнее можно прочитать по ссылке http://codeforces.com/blog/entry/8790. Такое нарушение правил может являться основанием для блокировки вашего аккаунта или других штрафных санкций. В случае повторения нарушений, ваш аккаунт может быть заблокирован.

and these two accounts belong to me, should I do something about it ?

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

C++17: 78738413 gives TLE C++17(64 bit) :78750670 AC Both of them are same code. Why this happens?

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

Learned Many things today....Thank you

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

Great round, thanks for super-fast rating updates and so well written prompt editorials(with easy to understand commented code)

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

Thankyou for hardwork. As it was said, short and clear statements. A lot of fun to solve. And become candidate master !!

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

A: 78733229 and A: 78665020

B: 78733627 and B: 78706022

C: 78734137 and C: 78731691

are exactly same.

Handle name is also almost same and submission time clearly indicates it's a cheating.

Please have a look FieryPhoenix

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

    submission times indicate that submissions of the first account within the contest, while all submissions of the second account outside the contest time, so I do not think this is a cheating.

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

      It was a 2 hour 30 min contest. So i think all the submission was during contest time.

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

    acts of cheating like this harms the rating of others

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

i passed problem E,but still have questions

i used $$$O(n^3)$$$ dp at first and got tle on pretest 33

then i used a list to optmize and passed

is the complexity right after i optimize the algorithm?

78735089 here's my solution

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

    You can ask in Luogu Discuss Area, some nice guys can help you there.

  • »
    »
    4 years ago, # ^ |
    Rev. 3   Vote: I like it +10 Vote: I do not like it

    Me too,I tried a $$$O(nm^2)$$$ dp and got TLE.

    And the next morning I changed my code and used less long long and % and it passed.

    Update:Fixed some stupid grammar mistakes.

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

Have anyone noticed that the checker comment in this round is "ok good job (xx test cases)"? Phoenix even makes the checker comment enjoyable:)

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

In my opinion, problem B was more difficult than most 2B's, but it is also one of the more interesting ones.

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

Thanks for the really nice set of problems.

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

ConstructiveForces

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

My O(n^3) dp isn't passing, getting WA in test 33. 78795957
Do we need something like O(n^3/x) to pass. And how can I optimize this?

»
4 years ago, # |
  Vote: I like it -22 Vote: I do not like it

Problem C is not clear. It can have many solution but it is accepting only unique answers.

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

    There are multiple optimal ways to distribute the letters but the answer resulting from the distribution is always unique.

»
4 years ago, # |
Rev. 2   Vote: I like it +18 Vote: I do not like it

Did anyone notice that there are hidden messages in test 31 of problem C?

Contents of test 31

(vcubingx is a YouTube channel. I do not know about the meaning of the other text in this testcase. Can FieryPhoenix provide an explanation?)