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

Автор chromate00, 7 месяцев назад, По-английски

Hello again! After merely eight days (personal record!) from my last contest, I gladly invite you to Codeforces Round 1082 (Div. 1, Div. 2) — which will be held on Feb/23/2026 17:35 (Moscow time)! For both divisions, you will be given $$$\mathbf{2.5}$$$ hours to solve $$$\mathbf{7}$$$ problems, where some problems may be divided into subtasks.

All problems of the contest are invented and prepared by myself.

I would like to thank:

The score distribution is as follows:

  • Div. 1: $$$(750+500) - 1250 - 1750 - 2250 - 3000 - (2750+1500) - 5000$$$
  • Div. 2: $$$750 - 1250 - (1000+750) - 1750 - 2500 - 3000 - (2750+2500)$$$

I wish you a thrilling experience in the round. Good luck and have fun!

UPD1: Added score distribution.

UPD2: Editorial (now complete!)

Also, congratulations to the winners!

  • Div. 1:
  1. tourist
  2. ecnerwala
  3. ksun48
  4. jiangly
  5. potato167
  • Div. 2 (Maybe subject to change when cheaters are found):
  1. JuanSign
  2. Joskmo
  3. rns_pis2
  4. Miaoborui
  5. foolnotfooling
  • Проголосовать: нравится
  • +172
  • Проголосовать: не нравится

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

As a VIP tester, congratulations chromate00 for the very orz personal record!

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

As a tester, I can confirm chromate00 authored between 0 and 9 problems.

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

chromaid my beloved

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

If my contribution back to positive, I will participate in this round, otherwise meh!
I am sick of this limitation because of low contribution:  I discovered this blog before any comment posted, I should be the first to comment if I'm not cursed like this :(

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

As an MVP tester, I demand a share of the author's compensation

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

A meme

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

strongest clash royale player js made another div

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

As a tester, chromate = chromaid

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

as a first time tester , wish you good luck and lot of positive delta

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

Where will the basement be this time?

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

I am glad to participate in your contest after eight days! Personal record (I'm participating chromate00's contests twice in 8 days)

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

As not a tester, problem A will not require XOR convolution in the intended solution

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

Back to back chromate rounds....so orz sir. Hope this one will be more good than the last one(it was good too :XD) :XD :XD :D :D orz orz orz chromate00

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

I'm going

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

Hope to reach my highest rating:)

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

Best of wishes to each contestant! Even though I’m not taking part.

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

34th comment

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

The problem A has 750 points instead of 500 in division 2... I don't know what will happen.

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

Hope to solve 3 problem

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

Hope to become specialist after this round

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

I have lost streak due to this maintenance.I was continuously solved for the fucking 71 days but due the website only which was not my mistake ,I have lost this continuity.

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

can't wait to see the editorial of div2B ... he he he !!!

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

    I found it very tricky but then I printed possible values and observed something and then just guessed based on that

    my observation was if we break string into chunks of 2.. both chars can't be same in a chunk .. and it passed pretests

    for me B >> both C

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

      This observation can be proved if we create a DFA of the states involved. These states would be involved:

      1. Odd length string starting with $$$a$$$
      2. Odd length string starting with $$$b$$$
      3. Even length string

      The transitions are

      • State 1 to State 3 if current character is $$$a$$$
      • State 2 to State 3 if current character is $$$b$$$
      • State 3 to State 1 if current character is $$$b$$$
      • State 3 to State 2 if current character is $$$a$$$
»
7 месяцев назад, скрыть # |
Rev. 2  
Проголосовать: нравится +6 Проголосовать: не нравится

Nice contest! <3 But… is this actually Div 2? It feels a little weird to me.

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

Very nice contest! I love problem B and C2, they are very cool :)

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

    how did you do B

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

      DP :skull

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

      invariant in parity of ?? continuous

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

      I did some bitmask magic to solve B: 364071388

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

        reading this code will kill my small number of brain cells .... aaaahhhh !!!

        can I please ask for mercy and request you to summarize the logic for me !!!

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

          There are 3 cases if in the middle of the process the string T is:

          • case 1: bab...bab: you can append at most 2 consecutive 'b' into S and can't append 'a' into S
          • case 2: aba...bab or bab...aba: you can append at most 1 'a' into S and at most 1 'b' into S
          • case 3: aba...aba: you can append at most 2 consecutive 'a' into S and can't append 'b' into S

          If n is odd, you start with case 3, if n is even you start with case 2

          Note that on case n, if you add a to S it will become case n-1, if you add b to S it will become case n+1, if ? is apper it means it can go to case n+1 or to case n-1, and after adding n strings to S, you want to end on case 2 (a and b is balanced).

          The bitmask part is not important, it is just to simplify writing the code. On my code case 3 (become mask 4 binary: 100), case 2 (become mask 2 binary: 010), case 1 (become mask 1 binary: 001).

          The bitwise operation become:

          • to go to case n-1 become binary right shift
          • to go to case n+1 become binary left shift
          • to go to both case n-1 and case n+1 using bit or for both logic above.

          If mask 2 is "on" at the end than it is possible, otherwise impossible.

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

      Indexing is 0-based.

      If n is even, then for every k, we must have {x[2k], x[2k + 1]} = {'a', 'b'}. The reason for this is because if n is even, if we pick from the front we get 'a' and if we pick from the back we get 'b'. But, if we pick 'a' from the front, then the front and back are both 'b', so we are forced to pick 'b' next. If we pick 'b' from the back, then both the front and back are 'a', so we are forced to pick 'a' next.

      If n is odd, you have to pick 'a' first and then you are left with n — 1 choices. Since n — 1 is even, the odd case actually reverts to the even case.

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

        yeah I guess that makes sense

        • ODD becomes even after one step but that step is fixed as character at both ends is 'a'

        • for EVEN you can either take 'ab' or 'ba' and then it again becomes an EVEN case so that is why chunks for size 2 are formed

        thanks this helps me clarify the logic a bit.

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

nice contest, enjoyed problem D

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

B >>>> D

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

$$$A$$$: Guess from testcases

$$$B$$$: Guess on your own

$$$C1, C2$$$: Good problem

$$$D$$$: Guess again

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

fuck ass contest

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

Amazing contest!, problems were so cool and enjoyable ^_^

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

Felt A harder than B :(

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

I couldn't solve A :-(

Could someone please give me an idea on how to solve it.

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

    realize that using the 1st operation and the 3rd operation is the same than using 2 time the 2nd operation, so that makes you realize that when u use 1st operation u just ignore 3rd and work with 1 and 2 op, and viceversa, after that u just make the 'y' be the one u want and check if u can make the 'x' to be what u want too, then if u can it's 'yes' otherwise 'no'

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

    Let $$$A, B, C$$$ be the number of moves of the mentioned types. Then we must have $$$(x, y) = A\cdot (2, 1) + B\cdot (3, 0) + D\cdot (4, -1),$$$ which is a system of equations over non-negative values $$$A, B, C$$$. Working out the system, you will get

    $$$B = (x - 2y) / 3 - 2C$$$ and $$$A = y + C$$$.

    Note that knowing the $$$C$$$ we will know $$$B, A$$$ using the above relations, in other words all solutions can be parameterized by $$$C$$$. We must ensure that

    • $$$C$$$ is non-negative
    • $$$(x - 2y)$$$ is divisible by $$$3$$$
    • $$$B$$$, $$$A$$$ are non-negative, which gives lower and upper bound on $$$C$$$ as $$$(x - 2y) / 6 \geq C$$$ and $$$C \leq -y$$$

    checking that all above conditions hold, gives the answer

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

    It was quite simple first bring y to 0 and change x accordingly and then check if x%3=0 ie if you can reach x with jumps of 3 which is 2nd operation.

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

    Think of it as a 1D problem instead of 2D. First try to reac y from 0. y can be reached from 1st operation (if y>0) or 3rd operation (if y<0). after reaching y check if the x we reached after reaching y <= target x or not (if not then return NO). now we just need to check if we can reach to target x or not. there is two type of horizontal movements we can do.

    use operation 2 to move 3 steps

    use operation 1 and 2 both and move 6 steps

    as 6 is a multiple of 3 itself, there is no point of using operation 1 and 2.

    so simply just check if the remaining distance in x direction is a multiple of 3 or not!

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

can anyone help me on how to optimize double for loop or is my approach a bit off

https://codeforces.me/contest/2202/submission/364095248

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

Div2 E is very nice problem, if the contest is ~30 minutes longer, I think could solve it. I love "thinking >>> coding" problems <3 Thank you problem-setters :D

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

Omg absolutely epic round with epic problems but a bit hard for div.2 I think.

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

First step of D1D is the same as the previous ICPC East Asia Final task.

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

wtf why my $$$\sum d(n) \log n$$$ got tle on 1E

i spent 1h optimizing it but still can't get through, 3.5s is to narrow i would say

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

    I kind of wanted to make them realize that sum of $$$d(n)$$$ is $$$\mathcal{O}(n \log \log n)$$$ and therefore the time complexity is fine, and then there's bitset solutions that pass within the TL unfortunately

    That being said all of our intended (including tester's) solutions pass in around $$$1.5$$$ s or less

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

C2 baited me to solve it, D was so much easier compared to it :tears:

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

Like the problem C2!

But missed D because of a silly miscalculation! :(

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

could anyone give me a hint on how to solve c1 .

i tried using below method

~~~~~~~~~~~ ll n; cin>>n; vector v; for(int i = 0 ; i <n ; i++){ ll temp; cin>>temp; if(i==0){ v.push_back(temp); continue; }

if(v.back() != temp) v.push_back(temp);
}

ll m = v.size();
vector<ll> dp(m,1);
int i = 1;
while(i < m){
   if(v[i]-1 == v[i-1]){
       ll maxi = v[i];
       ll mini = v[i-1];
       int j = i;
       while( j < m && v[j]-1==v[j-1]){
        maxi = max(maxi,v[j]);
        j++;
       }

       while( i < m && v[i] > mini && v[i] <= maxi){
        dp[i]=0; i++;
       }
   }
   else i++;
}

ll ans = accumulate(all(dp),(ll)0);
cout<<ans<<endl;

~~~~~~~~~~~~~

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

cheating situation is insane because i do NOT believe there's almost twice as many div 2 people that solved 1F1 compared to div 1 (and almost the same amount on 1F2)

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

Today I learned from 1D that if s is a set/multiset, s.erase(s.end()) runs forever (at least on my laptop)... Thankfully I still solved it in time regardless.

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

D was good, I loved it

couldnt solve it in time but solved it using queue

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

I think stepanov.aa getting -60 is a bit sus

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

Loved the contest!
Although couldn't solve E in time, but still liked it

Somehow i got negative delta, AI is improving so fast...(

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

https://codeforces.me/contest/2202/submission/364120605

this is my submission for C1 can anyone tell me where i am getting it wrong

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

C is absolutely trivial but I unfortunately wasted an hour trying to solve a misinterpreted version of it. I thought that you could only insert increments after the original m elements.

So, for example, for b = [1, 2, 3], f(b) = 2. But for b = [1, 1, 1, 1, 1, 2, 2, 3], f(b) = 6.

Oh well. Hopefully problem statements will be clearer in the future.

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

Does anybody know how hard the Problem D ( of Div.2 or problem B or Div.1 Recollect Numbers) is? It hasn't been shown in "tags"

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

--

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

chromate00 I am just curious why Div1 E wasn't included in Div2 as well. I guess the most obvious answer is the constraints on number of problems, but I believe that Div2 G1 and G2 were too difficult to have 100+ ACs (considering that most of the cheaters who submitted G1 only would have passed G2 as well). So, wouldn't be including Div1 E as Div2 G was better; or setters decided that convolution was a hard topic for a usual Div2 participant to know?

Just my opinion and assumptions, would love to know the thought process behind it.

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

    During testing phase we believed that Div2G1 < Div1E (the intended solution of Div2G1 is bitsets), and so I thought this change would allow more legitimate participants to get an interesting contest experience rather than a big difficulty spike (which, as I feel, many Div.1 participants are okay with difficulty spikes around late contest as it happens all the time?)

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

Why is the ranking shown on my profile page (4320) inconsistent with my ranking on the overall contest leaderboard (1471)?

Also, the virtual rating I calculated using the Carrot plugin is 1610, but my rating seems to have been adjusted based on the ranking shown on my profile page instead. Was there a mistake?

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

Hi, can somebody explain me how rating updating works?

I got -2 rating after round. In my profile you can see that I am on 1648 place. But if you open Div2 standings, I am on 343 place, and other participants with my rating received a positive delta.

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

Why the difficulty of F2 is lower than F1?