the_drunken_knight's blog

By the_drunken_knight, history, 15 months ago, In English


I was trying to apply some dsu-like logic in Problem E, when they asked for replacement of every $$$x$$$ with $$$y$$$ in the array, but it gave me WA on test 4.

The idea which I used during the contest:

from = replacement[x], to = replacement[y]
while(replacement[to] != to) to = replacement[to];
replacement[from] = to;

And, the idea which gave AC after the contest,

replacement[x] = replacement[y]

I know that the latter one is clever and more sleek, but why the former one fails? Can anyone please suggest a counter-case for it?

Except for these idea, the rest of code was exact same!

Submission 1 (with first logic):
Submission 2 (with second logic):

Full text and comments »

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

By the_drunken_knight, history, 21 month(s) ago, In English

While reviewing some of my suspected users, I found submissions of Js1.

If we closely at this guy's previous contest submissions:

We can easily deduct the following points:

  • He has changed his template 3 times (specially from B to C problem), in the 3 problems he solved,

  • In one of his previous contest, all of his submissions were skipped,

  • And all of his submissions were AC in one go, which clearly shows how desperate he was (like other cheaters).

It is near-to-impossible for MOSS to detect these kind of cheaters, so I request MikeMirzayanov to take some action (again as in that previous contest) over it. And also, needless to say, thanks for giving us such a great platform like Codeforces.

You da bestt!! <3

Full text and comments »

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