cdkrot's blog

By cdkrot, history, 6 years ago, translation, In English

Hi, codeforces!

I am happy to invite you to the codeforces round #493, which happens at Jul/01/2018 17:05 (Moscow time).

This round writers are — Ildar 300iq Gainullin, Grigory vintage_Vlad_Makeev Reznikov, Mike MikeMirzayanov Mirzayanov, and me, cdkrot.

Big thanks for people, who tested round — Shiqing cyand1317 Lyu, Andrew GreenGrape Rayskiy, Ivan isaf27 Safonov, Alexey Aleks5d Upirvitsky. Also thanks to Mike MikeMirzayanov Mirzayanov and Nikolay KAN Kalinin for help with round preparation.

And to Mike MikeMirzayanov Mirzayanov for codeforces and polygon systems.

Traditionally, there will be 5 problems for 2 hours. I hope you will enjoy the problemset, good luck and have fun!

Scoring distribution will be published before the round.

UPD: Scoring distribution is as follows:

Div1: 500 1250 1500 2500 3000

Div2: 500 1000 1250 2000 2500

You may also want to check this post for post-contest stream.

UPD2: The editorial was published!

UPD3: Congratulations to winners!

Div1:

  1. TLE
  2. ksun48
  3. fateice
  4. Swistakk
  5. Um_nik
  6. Petr
  7. V--o_o--V
  8. consecutivelimit
  9. LHiC
  10. uwi

Div2:

  1. kirisamejin
  2. liu_runda
  3. AntiLeaf
  4. TheFallenOne
  5. haj_lemon
  6. st-Firdavs
  7. traxex
  8. paladin
  9. kmyiu
  10. Maxim
  • Vote: I like it
  • +274
  • Vote: I do not like it

| Write comment?
»
6 years ago, # |
  Vote: I like it +159 Vote: I do not like it

Wow you've mentioned mike three times.

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

Are we allowed to code in Q#?

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

5 problems in both divisions?

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

Cool, we get to see 5 minutes of Spain-Russia.

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

    Unusual time for World Cup. :'(

    Have to solve all problems within 55 minutes to watch second up fully. :P

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

Finally Green GreenGrape!

I see what you have done with HTML ( ͡° ͜ʖ ͡°)

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

    Can you tell us, why do we need this information on page related to completely different round?

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

      I posted it here by mistake..I meant to post it in its round page,but i made a terrible mistake,sorry for that.

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

hope this contest has a lot of hacking stuff...:)

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

Upvote if you think the main characters of this contest should be Messi and Ronaldo.

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

Hope the statement be as short as the announcement XD.

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

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

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

Is It Rated?

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

Hope the statements is as short as the blog.

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

remember, I'll hack you!

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

?detaR tI sI

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

I would like to know from the community that is it fair that a re-submission which has the passed pretest should be considered for deducting points in a contest?

I had submitted one solution which i didn't think would pass the pretests so i re submitted with minor change before the result of first one but both the submissions passed the pretests, so i would like to know WHY or WHY NOT points should be deducted for the second correct re submission?

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

    Because there are system tests and only your second submission will be considered for system test.

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

      I m sry but i didnt get ur answer's relevance to my question and nor the point why only second one would be considered for the system testing?

      Btw do u mean my second submission or second solution which has passed pretests?

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

    The only situation when you actually have to resubmit is when you find a bug in your code after passing pretests. It's fair that you lose some points in this case since you didn't solve the problem correctly.

    In your case you were taking a conscious risk when resubmitting, since you hadn't seen the verdict yet for your previous submission.

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

      Fair answer

      But then why should the first solution that has passes the pretest be skipped? what if that solution had passed the main test cases...? why shouldn't i been given points according to that?

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

        cause there would be lots of such solutions, which CF would have needed to test, and that would take a lot of time.

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

        Because then sometimes I would submit 5 different solutions to a problem hoping that one of them passes systest.

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

          Whats the problem in that?

          U may deduct point for that during contest for multiple solution

          but if ur first ans is correct one out of those 5 then why shouldn't u be given points according to that? The system testing then can skip the rest of them.....

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

            Here's another problem specific to CF. Some people can troll by intentionally making holes in their solutions and make a bunch of pretests passes, then other people would benefit a lot from just hacking their solutions.

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

              Ya that can be difficult issue to deal with....

              I think that's it...

              Thank you all for your time

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

MathForces

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

Is it ridiculous to have two counting problems in one round?

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

Not the kind of problems that I hoped for

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

I finished A~D all within 31ms and 12KB...What a strange contest!

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

omg just don't tell me that this actually solves div1B/div2D

vector<int> a = {0, 4, 10, 20, 35, 56, 83, 116, 155, 198, 244, 292, 341};
if (n < a.size())
    return a[n];
else
    return a[12] + 49 * (n - 12);
  • »
    »
    6 years ago, # ^ |
    Rev. 3   Vote: I like it +19 Vote: I do not like it

    You only have to use the first 11 elements. I mean:

    vector<int> a = {0, 4, 10, 20, 35, 56, 83, 116, 155, 198, 244, 292};
    if (n < a.size())
        return a[n];
    else
        return a[11] + 49 * (n - 11);
    
  • »
    »
    6 years ago, # ^ |
    Rev. 2   Vote: I like it 0 Vote: I do not like it

    It is correct, see editorial (coming soon) for proofs.

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

    I hope not, because I did that but got WA on pretest 9 :(

    RIP forgot to cast to a long

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

      Me too. I used %d instead of %lld and got WA. FML

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

    int is too small

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

      I have #define int long long

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

    How did you get this equation?

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

      I found this by looking at the brute force and finding pattern

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

        I watch at it and didn't find anything for about 1.5 hour.....

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

          Look at difference of f[i+1] and f[i] for first 30 numbers for example and you'll easily see the pattern.

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

        What is the brute force for this ??

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

          Something like:

          set<int> st;
          for(int i=0;i<=n;i++) for(int v=0;v+i<=n;v++){
          	for(int x=0;x+v+i<=n;x++){
          		int l = n - i - v - x, cur = i+v*5+x*10+l*50;
          		st.insert(cur);
          	}
          }
          cout << st.size() << '\n';
          
          • »
            »
            »
            »
            »
            »
            6 years ago, # ^ |
            Rev. 2   Vote: I like it 0 Vote: I do not like it

            Deleted

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

            can you explain this in some simpler words? what are we trying to do here

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

              We just enumerate every possible combination of I, V, X, and L, and count the number of numbers we can represent.

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

        Can you tell your approach? Did you know from the beginning that a pattern should be found out?

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

          I wasted about 30 minutes trying differences and things on OEIS. Then I just said "wtf" and input 100 to my brute force and I was surprised at how small it was. Then I tried incrementing by 1 and noticed that each time it was always 49 increase. So I got to this solution

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

    I found that LIIIII && XXXXXV represents same number so, we need to subtract all the numbers containing them and then a got a weird recurrence relation but did not got the idea of find a pattern.

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

Why are there 2 combinatorics problems in this round, and why can B be solved with brute force observations?

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

    Because combinatorics is fun. Isn't combinatorics a very wide notion that can capture majority of CP problems?

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

1908 solved C, 344 solved D

The problems were not measured correctly

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

cheating ??

ILoveBitches

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

div2E/div1C was a hard one, IMO...

could somebody give a hint on its solution, please?

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

    Use inclusion-exclusion principle.

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

      how do you reduce it to O(n) though? When I tried inclusion-exclusion I had to do cases on # of equal columns and # of equal rows which is O(n^2)..

      (for example when there is at least one equal row and one equal column, I got )

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

        Fix r and use formula for (a + b)n

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

        sorry, but I'm a little bit confused :(

        shouldn't it be ?

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

          oops, i replaced r,c with n-r and n-c (it doesn't change the value)

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

            makes sense ^_^

            thanks :)

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

            if you don't mind can you please give me some advise on how to think in such kinds of problems?

            thanks :)

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

      It makes me incredibly happy that I (probably) fixed all the sign and off-by-one errors in C at 18:07.

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

Is there any way to hack consistently with regard to a segfault? There were a few times that I saw people accessing, say, s[n] when s only had n elements allocated to it, which should cause a segfault, but because of the magic of operating systems, segfaults only happen sometimes. These people will probably fail during systests, but I can't reliably hack because even if I submit a hack, the OS might not complain about a segfault and I'll get an unsuccessful hack. Is there any way around this or should I just not try to induce a segfault in a hack?

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

    I also faced this issue. I think there is no way to hack such solution surely. I hope MikeMirzayanov may do something to handle the issue, for example, some cases may be added so that such solution don't get accepted. But by this way solution may not even pass the pretests and thus no way to hack — I am not sure though.

    By the way, you may create a blog post regarding this.

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

nice algorithmic problems :p

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

Streaming now! Check out twitch.tv/ttocs45 for problem discussion.

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

too much math

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

    shouldnt be a problem for the great mathematician qkxwsm

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

So much counting problem :(

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

I bet a lot people tried oeis for div2D/div1B

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

    Yes I did. I took first 10 numbers as sample and that was a mistake.

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

I misread problem A, and I thought it was asking about a split in which the sums are equal (instead of unequal). So, I asked them about the second sample why there is no answer for such case and their response was:  They said "that one is also OK" and the correct answer should be -1, that made me confused for a lot of time at the beginning of the contest.

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

    Ouch, it is my mistake.

    I misread you question as regarding first sample, I am very sorry.

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

constraints of div2 B should be bigger

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

Can anyone prove the function of problem div2_D / div1_B ? Please help me.

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

What's wrong with Errichto?

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

When will we get data structures, graphs, etc , and not only math problems?

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

It's luck to compete in two math forces round 492 and 493... Lol, should run away from it for a short period.

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

    Just find we can open the round, count number of math problems, then decide if we play it or not.

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

Contest was completely Fine, But I honestly think codeforces should limit the math/geometry based problems to atmost 1..cause This is codeForces not MathForces

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

Any reason why system testing has not started?

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

Always a common scene after 20-30 minutes it will be started judging. What is the problem? -->After two hours contest, contestant are waited more than two hours before got rating. Hopefully, it will be fixed soon.

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

    There are many possible reasons why that happens.

    For instance, sometimes there are successful hacks on solution that is passing systests otherwise (note that if the load during the round permits, some or all solutions are run on systests during the round). As this is suspicious (it might happen that the hacked solution is in fact correct, and the reference one is incorrect), it needs some manual inspection before starting the systests.

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

Round was ended earlier than Russia vs Spain. What a surprise.

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

In div1.B, we should count how many difference a+5*b+10*c+50*d, where a+b+c+d == n.

We can notice that

if b == 1 && c == 5, a == 5 && d == 1, then a+50*d == 5*b+10*c && b+c == a+d;

if b == 9 , a == 5 && c == 4, then a+10*c == 5*b && b == a+c;

if c == 9 , b == 8 && d == 1, then 5*b+50*d == 10*c && c == b+d;

if we avoid all (b >= 1 && c >= 5) || (b >= 9) || (c >= 9), we can get the answer.

the answer is C(n+3, 3) — C(n-3, 3) — 2 * calc(n-6) + calc(n-7) + calc(n-11) = 49*n-247

sorry for my poor English :D

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

    if b == 1 && c == 5, a == 5 && d == 1, then a+50*d == 5*b+10*c && b+c == a+d;

    if b == 9 , a == 5 && c == 4, then a+10*c == 5*b && b == a+c;

    if c == 9 , b == 8 && d == 1, then 5*b+50*d == 10*c && c == b+d;

    How did you find these relations? Did you use any specific technique?

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

Can you explain 7s TL in D ?

39833354O(n2k)
39838295O(nk2)

It was hard to distinguish?

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

    Because we expected an solution, actually.

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

      Aargh, I wasted so much time trying to micro-optimise my O(n2k) solution which was within about a factor of 2 too slow (on my local machine at least), and then ran out of time when I saw how to do it in O(nk2). I had a working solution about 5 minutes after the end of the contest.

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

    I am very disappointed that MrDindows didnt solve this problem :(.

    I wrote O(nnk) first, but didnt manage to make it run faster than 17s. I was also confused by this TL.

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

Hackforces!!

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

Does anyone like me WA on A,B,C and AC D :(

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

      Just a small typo in A

      Should be 1 1

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

      Awwwew how careless i am, i printed 1 a[1] instead of 1 1 ... Arghhhhhh in B i missed a "=" in my if statement T_T rip me

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

Why are there always math questions whenever greengrape is associated with any contest, be it testing or writing? Because of her, i am always fucked in the contests. My cumulative decrease in rating is now 400 in contests related to that idiot greengrape.

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

What's the test 16 of Div2/C?

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

I hope you enjoyed the contest!

The editorial was published! Check it over there

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

The following submission for problem D in Python3 gives wrong answer:

39842076

Whereas the same submission in Python2 passed:

39846023

Why would this happen? Can somebody look into this?

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

    I am not sure, but maybe because of division? In Python 2, "a / b" is integer division if a and b are both integers, but in Python 3 it instead performs "actual division" (i. e. returning a fraction without rounding).

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

Really, that was my fix for C between pre-tests and AC...

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

    Use scanf(" %c", &c) (note the space before the format) to read a character after skipping whitespaces. This might save you a lot of trouble in the future when it comes to input :)

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

      I used getchar() in hope to "optimize" my solution. Btw, unwanted char wasn't space, it was \n :D.

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

        The term "whitespace" includes all characters such as spaces, endlines, tabs, carriage return, etc.

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

Your crafting.oj.uz ratings are updated!

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

I was looking forward to rating changes in comparatively easier Div 3 contests coming up soon. Alas!!

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

I don't know if this is the right place to comment about this or will make things better or worse, but I am commenting anyway, so I can say to myself that I at least tried. Codeforce has deemed that my solution to today's contest's div2 D has too many similarities with some other accounts and hence ruled me out of this competition, of course due to my own mistakes.

I just want to clarify that (no matter the result of it): I thought up, figured out and coded the solution of that problem all by myself and did not take any help from anybody or any other resources. Initially, I wrote a bruteforce code but it took up a lot of time when it was running for n=15. but n=11, 12, 13 and 14 were enough for me to figure out my solution based on pattern. my codeblocks was still busy with my bruteforce code so, I used ideone (and stupidly, it was public) to check my code for errors. and the rest is as it is now.

But of course, words are just words. I don't have that hard evidence that it was my own code. But I do have some points to show. Do note that it's not contest rating or such I am worried about, I am not blaming anyone other than me or asking for any sort of rating recovery. It's the reputation and shame that matters more to me. Right now, people who know me and friends can look at my profile and think I cheated, and that really hurts. If only at least that could be solved, it would mean the most to me. Without further ado, I will present the points which -might- prove that I didn't cheat at least.

  • This is my submission to div2 D. Note the first few lines please, the define declarations.
  • Now, if you please look at most of my previous submissions (not just of this contest), you will realize that I am using same lines of codes for a long long time.
  • Let's look at the codes of some people with whom I am accused of cheating. vbbvaddd79506 is the first such username. This is his submission of div2 C. This is the code of div2 D he copy pasted from when I was using ideone. See how the first few lines of codes (the define declarations) differ from his previous submissions? I am sure it's also true for all other users with whom I was accused of cheating too.

This should clear up that despite my mistake of using ideone in public mode, I at least didn't cheat and solved the problem myself. And I will make sure that I will never make such a mistake again. But the consequence of this naive mistake, the shame, that's what's killing me. If only there was a remedy to at least clear my name... :(

I am also adding my bruteforce code from which I found the pattern, not that it's any kind of proof or whatsoever.

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

    Aw. That's really unfortunate :/

    Knowing you irl, I knew something like this probably happened. Hope things work out for you, don't let it keep you down too much.

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

    afaik codeforces won't block you, just disqualify from this contest. So you shouldn't worry much about this situation, as well as you shouldn't hope for not disqualify — it's your responsibility that someone was able to steal your solution. In your place I would say "okay, today I learned something new, will be more careful next time".

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

      I definitely learned something new, and I sure as hell will be more careful next time.

      P.S.: The purpose of this comment is not to hope any reconsideration or because of fear of disqualification. I understand that the ideone debacle is completely my fault and don't blame anyone else. I just wanted to clarify myself in this comment.

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

    I have seen people using two IDE's on their PC for this kind of situation. I myself use Code::Blocks and Visual Studio. nsf25, you can take note, brother. :)

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

      Thanks, vai. I never faced such a situation during an individual contest before hence the mishap. I'll use a secondary IDE if the need arises. :)

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

Is it normal to show top 10 instead of top 5? :)

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

    I think it was a good decision in this case.

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

duliu math problems

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

can anyone explain me div2 B cutting problems.

if i cut at a position So i get two sections,So does the both section need to have same the numbers of odd number and even number.

like :

6 4

1 2 4 5 7 7 what's the output of this one?

1 2 | 4 5 | 7 7 is it possible?

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

    The problem statement states

    "There is a sequence of integers, which contains the equal number of even and odd numbers."

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

Did the author intend any pun when writing problem B statement by writing 'cut "the rope"?

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

It helps me a lot, I hope to get better and better.