Блог пользователя 0doO

Автор 0doO, история, 2 года назад, По-английски

Ciallo, codeforces~(∠・ω< )⌒☆

We are pleased to invite you to participate in Codeforces Round 939 (Div. 2), which will start on Apr/13/2024 17:35 (Moscow time).

The problems are from Otomachi_Una and me.

This round will be rated for participants whose rating is below 2100. Participants with higher ratings may participate out of the competition.

You will be given 6 problems and 2 hours to solve them. We hope you find them interesting.

We would like to thank:

Score distribution: $$$500-750-1500-1750-(1500+750)-2500$$$

Good luck on the round and high rankings to everyone!

UPD: Editorial out.

UPD: the winners

Div. 1 Div. 2
BurnedChicken zjy114514
StarSilk King_of_Beggars
maspy _MyGO_Tomori_
415411 LegendaryGrandmasterLjm
Rubikun naniak

Photo of authors (unfortunately, I can't come, so my profile is shown in the picture): photo

UPD: The rating changes for Educational Codeforces Round 164 will be applied after this round.

  • Проголосовать: нравится
  • +652
  • Проголосовать: не нравится

»
2 года назад, скрыть # |
 
Проголосовать: нравится +11 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится +14 Проголосовать: не нравится

Auto comment: topic has been updated by 0doO (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится +74 Проголосовать: не нравится

have mixed feeling of looking at pics.. registering contest written by literal 7-th grader (redcoder) from china which clearly 10^10 smarter than me.

why Chinese are so smart.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +25 Проголосовать: не нравится

As a tester,Otomachi_Una is very cute :)

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится +250 Проголосовать: не нравится

As an author, give me Contribution!

»
2 года назад, скрыть # |
 
Проголосовать: нравится +55 Проголосовать: не нравится

Me looking at the pic and wondered which rock had I been living under when I was grade 9 i.e. 11-12 years ago...

Kudos to the youngsters, and hope the contest run well.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +52 Проголосовать: не нравится

Ciallo~(∠・ω< )⌒★

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

qrz

»
2 года назад, скрыть # |
 
Проголосовать: нравится +89 Проголосовать: не нравится

»
2 года назад, скрыть # |
 
Проголосовать: нравится +16 Проголосовать: не нравится

As a big fan of yuzusoft(see my id), i will definitely enroll it though i have 3 college experiments tomorrow. Ciallo~

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Yu...Yuzu soft fan?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +41 Проголосовать: не нравится

Wish everything goes well!

»
2 года назад, скрыть # |
Rev. 3  
Проголосовать: нравится +12 Проголосовать: не нравится

Wish everyone gain more ratings, and me too :)

»
2 года назад, скрыть # |
 
Проголосовать: нравится +12 Проголосовать: не нравится

As a tester, I can confirm that round has some nice problems.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +41 Проголосовать: не нравится

As a tester, I ask you to:

  1. Play Omori to be as op as Yahia_Emara

  2. Play Hollow Knight to be as op as Octagons

  3. Downvote Heap_OverFlow for farming contribution

  4. Give me contribution

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

Hi! From Vietnam with love <3

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Nice picture! pretty sure it will be a good contest:")

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

As a tester, I hope everyone enjoys the contest!

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

yuzusoft round(

»
2 года назад, скрыть # |
 
Проголосовать: нравится +7 Проголосовать: не нравится

clear and short description we like it ...Ciallo~(∠・ω< )⌒★

»
2 года назад, скрыть # |
 
Проголосовать: нравится +42 Проголосовать: не нравится

It seems to be the same account.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Please I need cm :)

»
2 года назад, скрыть # |
 
Проголосовать: нравится +8 Проголосовать: не нравится

Ciallo~(∠・ω< )⌒★

»
2 года назад, скрыть # |
 
Проголосовать: нравится +8 Проголосовать: не нравится

I think I need to go to the library and play this round. Ciallo~(∠・ω< )⌒★.

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

Now imagine what the comment section will be like if it was a girl

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Who is this anime cartoon characters?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +42 Проголосовать: не нравится

我真是服了你们这种柚子厨了。

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

What if my rating is now < 2100, but if they give me a rating for the previous round, it will become > 2100 and I will not re-register for this round, will I write a rating or not?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +5 Проголосовать: не нравится

score distribution?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +1 Проголосовать: не нравится

wow

»
2 года назад, скрыть # |
 
Проголосовать: нравится +9 Проголосовать: не нравится

It is getting late to publish score distribution!

»
2 года назад, скрыть # |
 
Проголосовать: нравится +4 Проголосовать: не нравится

upvote!!

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

I hope the problem statements are short and clear.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

cute/qq

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится +21 Проголосовать: не нравится

operationforces

»
2 года назад, скрыть # |
 
Проголосовать: нравится +81 Проголосовать: не нравится

Constructiveforces.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

A question regarding problem D sample cases, did getting WA on test 2, 3 which are given in the statements used to always give penalty ?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +16 Проголосовать: не нравится

C is not a good problem.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +37 Проголосовать: не нравится

the worst C i have ever seen

»
2 года назад, скрыть # |
 
Проголосовать: нравится +1 Проголосовать: не нравится

D is actually not too hard, but it's somehow painful to implement

»
2 года назад, скрыть # |
 
Проголосовать: нравится +15 Проголосовать: не нравится

problem C in a nutshell : Wrong answer on pretest 2

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

ok, what was the edge case for C?

»
2 года назад, скрыть # |
 
Проголосовать: нравится -10 Проголосовать: не нравится

https://mirror.codeforces.com/contest/1956/submission/256521913

Can someone please tell me why do i get wa on pretest 6?

Basically my idea is that we can construct a sequence of operations that sets everything on interval of lentgh n to n

Then i do dp to get the best division

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

why does this retarded code for F runtime error i will kms 256536946

»
2 года назад, скрыть # |
 
Проголосовать: нравится +16 Проголосовать: не нравится

Feedback on the problems:

  • A & B: Both nice easy problems. However, it seems that difficulty of A = B.
  • C: Interesting constructive problem. The key is to observe the pattern of the final verdict of the matrix, then the construction is easy.
  • D: Not my favorite but okay. The data range gives a huge hint, and the method of using dp to calculate the answer is trivial. The implementation is a little too heavy (at least for me). And the pretests seem weak. (There are only 11 pretests. Why don't the authors use multi-cases?)
  • E1: Good brute-force problem. By simulating some small cases, especially the case when the ring has been reduced to a chain, you can come up with the key idea. My favorite problem from this round. However, the pretests seem weak.
  • E2: I don't really get the main idea of setting the harder version. Just by brute force, I passed it again. Maybe because of the weak pretests?
  • F: Not read.

In all, this round seems to be a good one (if the pretests are strong). Thanks to the authors!

»
2 года назад, скрыть # |
 
Проголосовать: нравится -8 Проголосовать: не нравится

Figured out a solution for c, but contest is over by 1 minute.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +8 Проголосовать: не нравится

Too large problem statements for A and B. And difficulty gap between B and C is huge. Getting big negative delta :(

»
2 года назад, скрыть # |
 
Проголосовать: нравится +6 Проголосовать: не нравится

C made me played like a fool. Haha, being outsmarted by youngsters...

Late submissions were when I realized how beautiful and simple the solution was, and I wished I solved it sooner.

  • »
    »
    2 года назад, скрыть # ^ |
     
    Проголосовать: нравится 0 Проголосовать: не нравится

    Can you explain how you came up with the correct approach for the problem C ?? My strategy was like first, apply first operation in all n rows. Now starting from first column check if the sum of the column is less than "n*(n+1)/2". If it is then the second operation should be applied. So the total number of operations applied were "n + cnt_col". But when the contest was over and I saw the further testcases then I realised the correct way to maximise the sum. So my question is, how did you come up with the correct solution in the first place ??

    Because seeing this type of solutions now I've started fearing and getting anxious that would I even be able to come with such smart and clever solutions ever ??

    • »
      »
      »
      2 года назад, скрыть # ^ |
       
      Проголосовать: нравится +3 Проголосовать: не нравится

      I actually got into the same mental trap as you, and took a very long while testing locally and observing my own output to figure out my errors.

      Spoiler

      No advice on constructive problems as a whole either. I'd just say that let your imagination grow wide, experiment with many things, and also simultaneously hone your instincts at detecting things going right.

    • »
      »
      »
      2 года назад, скрыть # ^ |
       
      Проголосовать: нравится 0 Проголосовать: не нравится

      For what it's worth, I also got WA at first, and with the same strategy as you. But, after getting WA, I tried the case of $$$n = 3$$$, which gives useful intuition for the other cases (the optimal final matrix you want to get). Then, I tried $$$n = 4$$$, but couldn't do it in $$$\le 8$$$ operations. Then, I drew out the entire thing for $$$n = 4$$$, and stared at it for 5 minutes or so before finally realising that "oh I can just overlay stuff". In my opinion, the last part was the hardest one, because everything before that can be done using trial and error, but this requires a "flash of inspiration", so to speak.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +44 Проголосовать: не нравится

I hate the long story statement of A. long statement is ok in long contest only (:

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +11 Проголосовать: не нравится

any idea how to solve C ? was stuck on it for the whole contest :(

»
2 года назад, скрыть # |
 
Проголосовать: нравится +14 Проголосовать: не нравится

0 hack attempts among 20k+ people :(

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Can someone explain why iam getting wa on my submisson for C :256512434

»
2 года назад, скрыть # |
 
Проголосовать: нравится +9 Проголосовать: не нравится
1 2 3 4
2 2 3 4
3 3 3 4
4 4 4 4

is C basically build this pattern in 2 * n right? cannot prove but it seems impossible

»
2 года назад, скрыть # |
 
Проголосовать: нравится +1 Проголосовать: не нравится

I don't really know why C took so long to solve for me... Actually, solved D much faster, lol.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +8 Проголосовать: не нравится

Really great contest, I especially liked problem D. Unfortunately I couldn't code it up in time.

  • »
    »
    2 года назад, скрыть # ^ |
     
    Проголосовать: нравится +3 Проголосовать: не нравится

    Me too. I came up with a solution but missed it by 2 minutes. Will validate my solution after system testing is over.

  • »
    »
    2 года назад, скрыть # ^ |
    Rev. 2  
    Проголосовать: нравится 0 Проголосовать: не нравится

    Not sure why people are liking problem D, but the brute force with bitmask was very intuitive and very well fitting the complexity given the constraints.

    Usually D is harder than normal brute force, or did I miss something?

    https://mirror.codeforces.com/contest/1956/submission/256577486 (Although I couldn't make it up on time for contest because of one bug), but here in brute force I just tried all possible masks and chose the one with best ans & least changes.

    • »
      »
      »
      2 года назад, скрыть # ^ |
      Rev. 2  
      Проголосовать: нравится +13 Проголосовать: не нравится

      I you only care about the answer, you can solve it in $$$\mathcal{O}(n^2)$$$ time complexity with a really cool observation, which is the reason why many people like it I guess. The reason why problem author set $$$n \le 18$$$ is because there could be $$$2^n$$$ steps in the construction.

      • »
        »
        »
        »
        2 года назад, скрыть # ^ |
         
        Проголосовать: нравится 0 Проголосовать: не нравится

        Can you share how to find the answer in O(n^2).

        • »
          »
          »
          »
          »
          2 года назад, скрыть # ^ |
           
          Проголосовать: нравится +3 Проголосовать: не нравится

          By noticing for every subsequence of length $$$L$$$ you can turn it to $$$L,L,\cdots,L$$$.

          • »
            »
            »
            »
            »
            »
            2 года назад, скрыть # ^ |
            Rev. 2  
            Проголосовать: нравится 0 Проголосовать: не нравится

            Thanks for the reply.

            I also made an observation during the contest and it got AC but am unable to prove it-

            if f(l,r) denoted the ans for subarray a[l,r] then

            f(l,r)=max((r-l+1)^2,f(l,i-1)+a[i]+f(i+1,r))

            where i is the index of the maximum value in the subarray. Can you help prove it or find a conuterexample.

            • »
              »
              »
              »
              »
              »
              »
              2 года назад, скрыть # ^ |
               
              Проголосовать: нравится 0 Проголосовать: не нравится

              It's easy to prove. First you need to observe that you only need to prove the case that all elements are 0.

              And then you can do it recursively, assume you can set the $$$a_i$$$ to $$$i-1$$$. If you want to set $$$a_{i+1}$$$ to $$$i$$$, all you need is to first let $$$a_i = i-1$$$, then $$$a_{i-1} = i - 2$$$, $$$\dots$$$, $$$a_1 = 0$$$. Now you can operate on $$$[1,i+1]$$$, and $$$a_{i+1}$$$ is $$$i$$$ now.

              So at the end, you can set every $$$a_i$$$ to $$$i-1$$$, and operate one more step $$$[1,L]$$$, you can set every element to $$$L$$$.

              • »
                »
                »
                »
                »
                »
                »
                »
                2 года назад, скрыть # ^ |
                 
                Проголосовать: нравится 0 Проголосовать: не нравится

                I wasnt asking about that actually i wanted to prove or disprove the observation that i mentioned in my prvious reply that its always optimal to either make the whole array eqaul to r-l+1 or partition the array around the maximium of the array that is leave the maximum of the array as it is and maximise the answer for the subarray that is to the left of the maximum element and also the subarray that is to the right.

                refer to my previous reply for the transition im talking about

                • »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  2 года назад, скрыть # ^ |
                   
                  Проголосовать: нравится 0 Проголосовать: не нравится

                  I don't know what is needed to be proved.

                  Because looking at every longest subsequence that is being operated, the maximum value that every value could be is the length of the subsequence, so if you want to operate something, the optimal way is to do this.

      • »
        »
        »
        »
        2 года назад, скрыть # ^ |
         
        Проголосовать: нравится +16 Проголосовать: не нравится

        you can solve it in O(nlogn) time

        dp[i] = max(dp[i — 1] + a[i], dp[j] + (i — j)^2)

        You can use Convex Hull trick to handle the second transition

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

very bad C, and nice D

»
2 года назад, скрыть # |
 
Проголосовать: нравится +4 Проголосовать: не нравится

Pretty good contest!

I liked D so much (the limit on the number of operations is chosen carefully!).

»
2 года назад, скрыть # |
 
Проголосовать: нравится -8 Проголосовать: не нравится

don't let these authors make contest Mike.

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

For my 1st contest i only managed to get A and B right lol

Can someone give me an hint for E1 pls ? It kept reaching the time limit on pretest 11 and I had no idea on how to reduce the time complexity. https://mirror.codeforces.com/contest/1956/submission/256528779

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

C is really great, it took me so much time tho, but I love this one.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

10**100 is quite ridiculous.
Interesting problem description.

»
2 года назад, скрыть # |
Rev. 3  
Проголосовать: нравится +76 Проголосовать: не нравится

A: If number of players is not greater than a[1], the game is end, otherwise it will continue. Then the answer is min(n, a[1]-1).

B: Assume we have t pairs and n-2*t single cards, then the opponent will also have n-2*t single cards, and then, they have (n-(n-2*t))/2 = t pairs. Since we can always get t points from pairs, and we can only get other n-2*t points if we play these single cards after opponent plays the corresponding cards, we need to play pairs first and single cards later. So for the first 2*t turns both players will play all pairs, and then we can't get any point because the opponent will play the card we've played last turn. So the answer is t.

C: From the example for n=2 we can see we can't get {{2, 2}, {2, 2}}. In fact, for any n and pairs (i1, i2) and (j1, j2) with i1<i2, j1<j2, we can't make numbers on the 2x2 submatrix determined by row i1, i2 and colomn j1, j2 be the same. So there can be at most 2*n-1 occurences of n (they can occupy a row and a column), and for the remained n-1 rows and columns, there can be at most 2*(n-1)-1 occurences of n-1 and so on... Therefore, the maximum sum we can get is sum(i=1...n)(i*(2*i-1)=i*(i+1)*(4*i-1)/6. To achieve this value, we can make operation on the i-th row and column, from i=n to i=1, with p[j]=j.

D: Let f(L, R) means we want to make a[L]=0, a[L+1]=1, ..., a[R]=R-L. If L==R, we can achieve this by do operation on [L, L] if a[L]>0. Otherwise, we can first do f(L+1, R), then do operation on [L+1, R] to make a[R]=R-L, then do f(L, R-1). Therefore, for any range [L, R] we can make the sum on this range be (R-L+1)^2 by operations, which is also the maximum possible value if every element on [L, R] have been modified. So we can solve the problem by dp.

E1: Assume i-th to (i+2)-th monster survived for T turns. If in the last turn (i+2)-th monster takes D damage, then at j turns before, it takes at least D+j damage, so the total damage it take will be at least D+(D+1)+...+(D+T-1) >= T*(T+1)/2, which means T*(T+1)/2 <= a[i+2]. Therefore, if we let A=max(ai), then after O(sqrt(A)) turns, there will be no more than 2 consecutive alive monsters, then for any pair of adjacent alive monsters, the left will be alive the the right will die. So we can brute solve the problem by brute force.

E2: Similar with E1, there will be no more than 3 consecutive alive monsters after O(A^(1/3)) turns, but we need to calculate the total damage of the second monster, in order to determine whether the third monster alive for consecutive 3 monsters.

»
2 года назад, скрыть # |
Rev. 4  
Проголосовать: нравится 0 Проголосовать: не нравится

In problem c didn't we had to make matrix as

Спойлер

For that first we will fill rows 1 to n with Permutation 1 2...n and then set n=n/2 and do the same with columns This was my approach why did it fail

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

Very nice problems. I am waiting to see the pretest number 21 on E2 :D. Maybe 15 more minutes would have been nice but maybe its just me that i am slow at finding solutions for problems like C.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +10 Проголосовать: не нравится

very good round,make me back to expert AGAIN!

I love yuzusoft ans it's fans,because of u my friend.

Ciallo~(∠・ω< )⌒★

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

couldn't solve C 💩 bye bye rating

»
2 года назад, скрыть # |
 
Проголосовать: нравится +4 Проголосовать: не нравится

Not Gona Lie , Problem C really Sucked

»
2 года назад, скрыть # |
 
Проголосовать: нравится -9 Проголосовать: не нравится

C is beautiful, was stack for whole contest because was trying to construct

1 2 3 4
2 2 3 4
3 3 3 4
4 4 4 4

instead of

4 4 4 4
4 3 3 3
4 3 2 2 
4 3 2 1
»
2 года назад, скрыть # |
 
Проголосовать: нравится -12 Проголосовать: не нравится

It would have been neater if C only outputted $$$\sum a_{i,j}$$$, and if D were given as $$$a_i\le n$$$. Personally, I found it a bit cumbersome to write unnecessary subroutines.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +7 Проголосовать: не нравится

The C is too difficult for me to come up with the correct construction of the matrix. Huge thinking traps! I determined to use the permutation to fill the matrix in the first n steps and all my attempts were on modification in the rest of n steps, which meant I will never get the correct answer!

  • »
    »
    2 года назад, скрыть # ^ |
     
    Проголосовать: нравится +2 Проголосовать: не нравится

    Seeing the terrible rank and the very few people solving D I was regret giving up C at first,but regret giving up C too late after I know the solution. It's just impossible to think of this strategy if you start in a totally wrong way.

  • »
    »
    2 года назад, скрыть # ^ |
     
    Проголосовать: нравится 0 Проголосовать: не нравится

    had exactly same thought from the constraint 2 * n, since n + n / 2 + n / 4 ... + 1 < 2 * n so it MUST has something to do apply operation n times on row, n / 2 times on col and so on. kek

»
2 года назад, скрыть # |
 
Проголосовать: нравится +7 Проголосовать: не нравится

Brick on random C again. Now you are my new nightmare photo boy.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

When a person has a anime girl DP, Run as fast as possible XD

»
2 года назад, скрыть # |
Rev. 3  
Проголосовать: нравится 0 Проголосовать: не нравится

TLE on A on system tests. Nice Update: WA on E1 on system tests. Range of emotions throughout the contest xD

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

I sense weak pretests

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Weak pretests for E2

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

What an excellent contest — well done!

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

TLE systest on A just for using maps instead of linear soln?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +12 Проголосовать: не нравится

D is a really cool problem!

»
2 года назад, скрыть # |
 
Проголосовать: нравится +35 Проголосовать: не нравится

The lesson you should learn from problem C: Don't touch your f*cking keyboard if you're not 100% sure about your solution.

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится +29 Проголосовать: не нравится

Lengthy statements even for A, B. Weak-pretests for literally every problem on the contest (A, B, D, E1, E2)

»
2 года назад, скрыть # |
 
Проголосовать: нравится +6 Проголосовать: не нравится

rating changes when? 2 contests have pending changes

»
2 года назад, скрыть # |
 
Проголосовать: нравится +7 Проголосовать: не нравится

My D received runtime error in the System test. I submitted it using C++17 (GCC 7-32). After system test, I submitted the same code using C++20 (GCC 13-64), and it was accepted.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +1 Проголосовать: не нравится

Whe the rating changes for Educational Codeforces Round 164 will be applied after this round?

»
2 года назад, скрыть # |
Rev. 2  
Проголосовать: нравится +14 Проголосовать: не нравится

Leaving aside the weak pretest of E, it's a very good contest!

Ciallo~(∠・ω< )⌒★

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

what is the meaning of last announcment about rejudging ?

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

C is a beautiful problem with a simple solution. I have to accept that I am simply not good enough to solve these at my current level. One day hope to be able to solve problems like these fast.

»
2 года назад, скрыть # |
 
Проголосовать: нравится +14 Проголосовать: не нравится

Finally CM, thank you all!

»
2 года назад, скрыть # |
Rev. 3  
Проголосовать: нравится +13 Проголосовать: не нравится

I believe my solution idea 256566371 to E2 can be adjusted for much higher values of a_i, tho it's not too different then what seems intended by other comments (also my submission is current fastest btw).

As others, I use it will take A^(1/k) rounds for there to be at most k in a row. However, I can also solve for small k in a row in O(k^3 * lg(A)) time. To do this, I found formula for how much each previous value will change current one after exactly x turns (just analyze pattern by keeping values as variables). Now you just use binary search for how many turns rounds until they one becomes 0.

Now just find optimal k where brute forcing initial rounds is as fast as solving remaining small sequences, and using wolfram it seems that for n=2e5 A=1e18 having k = 8 will solve in reasonable time.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

My solution for D (which I believe is intended) reminds me a lot of the tower of hanoi, which can be solved using a similar recursive idea.

  • »
    »
    2 года назад, скрыть # ^ |
     
    Проголосовать: нравится +5 Проголосовать: не нравится

    Yeah, exactly my thoughts after reading the solution of YocyCraft. I thought it was some dumb bruteforce/bitmask dp and got stuck on that idea for a while, but that observation was beautiful.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Were the pretests for problem E1 and E2 purposefully made weak, to stop people from guessing the solution?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

Is it intended that people who became orange from the edu round had the contest rated for them? Of course, I'm only asking because I did poorly ;)

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Editorial?

»
2 года назад, скрыть # |
 
Проголосовать: нравится +1 Проголосовать: не нравится

Why weak pretest?? I made a very stupid mistake on D,but it still pass the pretest???

»
2 года назад, скрыть # |
 
Проголосовать: нравится -21 Проголосовать: не нравится

Codeforces Hot News! Wow! Coder bro_jie competed in Codeforces Round 939 (Div. 2) and gained ??? rating points taking place 1,151!!!!

WDF D>>>>>>>>>>C

Stuck on Div.2C for the first time ever!

good contest it is,nooooooooooob I am!

»
2 года назад, скрыть # |
 
Проголосовать: нравится +5 Проголосовать: не нравится

How to solve D ? Can someone explain in simple words ?

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

what's the point making the limit of problem F so tight

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится +3 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

My favourite contest so far. Unfortunately, I was not able to participate during the contest itself :(

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by Otomachi_Una (previous revision, new revision, compare).

»
2 года назад, скрыть # |
 
Проголосовать: нравится +10 Проголосовать: не нравится

very badly worded problems.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

The contest was good even though I didn't rank high

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

As a grade 10 student, I must said that you are really talented. The best student in my school (my classmate) only reach master.

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Can anyone explain how you came up with the correct approach for the problem C ?? My strategy was like first, apply first operation in all n rows. Now starting from first column check if the sum of the column is less than "n*(n+1)/2". If it is then the second operation should be applied. So the total number of operations applied were "n + cnt_col". But when the contest was over and I saw the further testcases then I realised the correct way to maximise the sum. So my question is, how did you come up with the correct solution in the first place ??

Because seeing this type of solutions now I've started fearing and getting anxious that would I even be able to come with such smart and clever solutions ever ??

  • »
    »
    2 года назад, скрыть # ^ |
    Rev. 2  
    Проголосовать: нравится 0 Проголосовать: не нравится

    Authors did correct thing only including $$$n = 1, 2$$$ testcases. I am sure, that there are two ways how to come up with the solution. $$$1.$$$ I tried to solve $$$n = 3$$$ case and after getting one non-trivial result i sent it and get AC. The second way is try to prove bounds, but it's not necessary during contest

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Upsolved E2, shouldn't it be "Meguru VS. Monsters"?

That way C can be renamed as "Touko's favorite cake". So where can Tsumugi and Wakana show up?

»
2 года назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

I think it's super mentality