Comments

Did anybody from the finals got the prize money ?

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

Where can we upsolve the problems of the contest ?

On cjtoribio → Venice Technique, 9 years ago
0

I also did a similar thing during the contest.
I used a dynamic segment tree but instead of performing lazy propagation for update all I used similar technique of maintaining a level.
Link to my submission : http://codeforces.me/contest/948/submission/36168355
In the code anss contains the current level.

Could you give a slight overview of this segment tree ?

Usually 1 sec is equivalent to 1e8 operations.That's why your solution exceeded the time limit. Btw I implemented an O(N*N*26) solution.

Good strategy. I will follow your thread too :)

I thought it is O(n).Thanks for the info.

We cannot use the size function of the set to compare the sizes of the set as it would otherwise lead to N^2 complexity.Am i right?

On Kniaz → Codeforces Round #378 (Div. 2), 10 years ago
0

Yes your logic is correct.I implemented the same logic during the contest.