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

Автор Monogon, история, 3 года назад, По-английски

¡Buenos días! (That's Spanish for "what's up homies")

On Dec/06/2020 17:35 (Moscow time) we will host Codeforces Global Round 12.

It is the sixth round of a 2020 series of Codeforces Global Rounds. The rounds are open and rated for everybody.

The prizes for this round:

  • 30 best participants get a t-shirt.
  • 20 t-shirts are randomly distributed among those with ranks between 31 and 500, inclusive.

The prizes for the 6-round series in 2020:

  • In each round top-100 participants get points according to the table.
  • The final result for each participant is equal to the sum of points he gets in the four rounds he placed the highest.
  • The best 20 participants over all series get sweatshirts and place certificates.

Thanks to XTX, which in 2020 supported the global rounds initiative!

The problems were written and prepared by smart Cuban Devil and stupid Americans fivefourthreeone and Monogon.

We would like to distribute our thanks equally to the following people who made this round possible.

You will have 3 hours to solve 8 problems (and 2 subtasks). If you want to lose rating, then we encourage you not to read all the problems.

May rating be distributed from each according to his ability, to each according to his needs!

UPD: Here's the score distribution. Good luck, have fun!

$$$500-750-(1000+750)-1750-2500-2750-3750-(2750+1750)$$$

UPD: Hope you enjoyed the problems! Editorial is posted.

UPD: System testing finished, congrats to the winners!

  1. Benq
  2. tourist
  3. jiangly
  4. IZONE
  5. ecnerwala
  6. Um_nik
  7. ksun48
  8. 244mhq
  9. maroonrk
  10. yosupo
  • Проголосовать: нравится
  • +1239
  • Проголосовать: не нравится

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

As a tester, Communism is a good and realistic economic and political system.

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

As a communist, Testing is a good way to contribute to competitive programming community.

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

How to improve contribution? Negative->positive

»
3 года назад, # |
  Проголосовать: нравится -145 Проголосовать: не нравится

An announcement written 4 days before the contest -> bad contest

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

As a tester,

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

I'm afraid I can't participate in it because I have to go back to school to have classes then :(

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

Since fivefourthreeone currently refuses to post here and gain contribution, please give him contribution!!

He is very orz and write problem good.

If you want to gain rating on this global round, upvote his posts!

https://codeforces.com/blog/entry/80268#comment-664350

https://codeforces.com/blog/entry/82050#comment-687962

https://codeforces.com/blog/entry/82288#comment-691417

https://codeforces.com/blog/entry/82468#comment-693597

https://codeforces.com/blog/entry/82468#comment-693602

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

As a tester, give me contribution

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

I cannot wait for the opportunity to generously hand out rating to the needy in this upcoming Global Round!

I live to serve the community!

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

Why doesn't fivefourthreeone make a comment asking for contribution?

Because he doesn't have two!

»
3 года назад, # |
  Проголосовать: нравится -20 Проголосовать: не нравится

"Your participation will directly contribute to the end of the long-standing Cuban-American rivalry."

You assumed there's an end :).

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

I actually anticipated an "As a problem setter ..." comment :(

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

[deleted]

»
3 года назад, # |
  Проголосовать: нравится -50 Проголосовать: не нравится

As a non-tester, give me negative contribution.

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

    Maybe, you should change it to "As a non-tester, give me non-negative contribution". xD

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

May the pretests be strong!

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

May the problem statements be short!

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

May the round remain rated forever!

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

I thought "Buenos días" is "Good morning" — from a terrible student failing Spanish Class xD

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

I thought "what's up homies" in Cuba is said as "Que bola asere!"

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

As a tester ... ( You know what's next [^-^] )

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

As a tester, Monogon asked me to test just so I could write a comment in this blog saying that the problems are fun.

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

    As a setter, I can confirm that you are a tester and I forgot to update the tester list.

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

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

I feel bad for namanbansal013. He has negative contribution just because he made video editorials for some problems. Come on people, he ain't getting monetary benefits for making editorials. Neither has he posted some random shit "as a tester" comment (that doesn't make any sense) just to farm contribution in any of the rounds he tested. No tester should have negative contribution

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

Hope not to become expert again XD

»
3 года назад, # |
  Проголосовать: нравится -23 Проголосовать: не нравится

I rarely write a comment but it is really annoying that people upvotes a comment just by seeing handle's colour

»
3 года назад, # |
  Проголосовать: нравится -15 Проголосовать: не нравится

As a tester, Monogon asked me to test just so I could write a comment in this blog saying that the problems are fun.

»
3 года назад, # |
  Проголосовать: нравится -13 Проголосовать: не нравится

Monogon is one of my favourite writers :)

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

Its weird how newbies and pupils most of the time gets downvoted because of their comments (which I agree are really bad sometimes) but from last few contests high rated beings just commenting literally anything like "As a tester" comments and still getting upvotes.

Like once errichto said- "This comment section is shit"

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

Congrats Monogon on 200 contribution!!

»
3 года назад, # |
  Проголосовать: нравится -36 Проголосовать: не нравится

Whatafuck!!!

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

I am a newbie here and haven't given many contests yet. Can someone please explain what are subtasks that are mentioned in the above post. Does that mean we will have 10 questions in total?

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

    It means that 2 of the problems will be split into an easy version and a hard version.

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

Glad to see saurabhyadavz as a tester of this contest from my city.

»
3 года назад, # |
  Проголосовать: нравится -31 Проголосовать: не нравится

The problems were written and prepared by smart Cuban Devil and stupid Americans fivefourthreeone and Monogon

That's harsh XD

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

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

As a cuban, I am very proud of the cuban testers and writers & after living in "communism" for long time, I just wanna say that "It sucks" :)

»
3 года назад, # |
Rev. 4   Проголосовать: нравится -19 Проголосовать: не нравится

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

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

As a non-tester,I am pretty sad that I missed my chance to get contribution with saying "As a tester".

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

Monogon orz!

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

    We have actually prepared 2 entirely different problem-sets. One which Errichto will surely get huge +, and the other he will surely get huge -. The one we choose will depend on whether he gives in to my demands.

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

      7 geometry problems?

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

        Can you make some geometry videos in your YouTube channel ?

        Personally I think some of competitive programmers see the geometry as the hardest thing in CP

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

It should be: from each according to his ability, to each according to his work!

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

Hello Comrade Problem-setters. It pleases me greatly that rating redistribution will finally become a reality on Codeforces. I'd like to ask how exactly each user's need for rating will be determined.

Sincerely, Comrade Contestant Darcy

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

can i get some upvotes/contribution please , today is my birthday !!

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

Will the problems be available in Spanish?

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

"May rating be distributed from each according to his ability, to each according to his needs!" *his or her

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

This is the first global contest that I am going to participate in. Is a global contest harder than Div.2? Can you tell me the difference between a global round and other rounds? Also, is a global round rated for me?

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

    Global is rated for you. Typically, Globals are harder than Div. 2 because it is combined Div 1 and 2. Globals are known for their interesting high quality problems, although I'm not sure what differentiates them from regular Div. 1 + Div. 2.

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

Буду рад поучаствовать

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

For a Chinese primary school student, the start time is too late:(

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

 2 points left Monogon

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

Why Errichto didn't Host a single contest on Codeforces in last one year.

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

Screenshot-2020-12-06-164243.png
Now this actually strikes chills down my spine

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

Now all makes sense ... He's the emo spiderman.

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

    Why don't you all memers put your shitty memes inside spoilers. Just cluttering the comments section with shit

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

Well, hope the problems are not too difficult for me :)
By the way, when can we see the scoring distribution?

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

I can smell maths from here .

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

I hope I am not going to mess it up again.

Capture.png

»
3 года назад, # |
  Проголосовать: нравится -61 Проголосовать: не нравится
Комментарий удален по причине нарушения правил Codeforces
»
3 года назад, # |
Rev. 3   Проголосовать: нравится +4 Проголосовать: не нравится
  • Yesterday : Tourist win hackercup
  • Today : May be cross highest codeforces rating ( if all goes well )

Best weekend for tourist

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

For me, this round was very tough. I don't even solved B even after 3 hours :(

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

So I couldn't solve C1, but on the bright side, I figured out how to make a sound while breathing inwards by making monkey noises for the past 20 minutes!

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

I hate every contest with subtasks specially in the first 3 problems.

»
3 года назад, # |
  Проголосовать: нравится -6 Проголосовать: не нравится

What is probability of a person like Me(an average mind) thinking the same puzzle in same way as a Red coder thinking randomly in his Leisure time?? is that 1/6e4 like that??

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

Solve F in 20 minutes Can't solve C2 or D in 2 hours.

How it works???

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

    I think a lot of people spent time with c or d so just a small group of contestans read problems up to F

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

    I am not sure of the system tests at the moment, but binary search worked for $$$D$$$, with just checking for $$$k = 1$$$ separately (actually I did check for the first $$$10$$$ arbitrarily). Find minimum $$$k$$$ for which the goodness holds, then all $$$k$$$'s till $$$n$$$ from this point will hold. Checking for a permutation is trivial, and sliding window minimum is also very standard.

    I hope system tests pass for me.

    I did find $$$C$$$ much harder than $$$D$$$ though.

    Update: Accepted
    Solution: 100575348

  • »
    »
    3 года назад, # ^ |
    Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится
    Hints for D
»
3 года назад, # |
  Проголосовать: нравится +29 Проголосовать: не нравится

This is really tough problemset :|

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

How to solve C2?

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

    First, split the matrix on three groups:

    0120120
    1201201
    2012012
    0120120
    1201201
    2012012
    0120120
    

    where group[i][j]=(i+j)%3

    Then choose such two different groups where number of 'O' in the first group + number of 'X' in the second group <= k/3. Such pair of groups always exists. Finally, in the first group all 'O' replace by 'X' and in the second group all 'X' replace by 'O'

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

      I took all masks 1 <= mask <= 6(not all 0 and not all 1) and decided for each remainder MOD 3 of (i + j) what I want it to be(X or O). I simply computed how many cells I need to change and if it's enough, output. This doesn't always find solution and u can prove it by simple math. I didn't figure out that you could ignore one remainder. Oh well

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

Seriously now, who decides the difficulty for these contests?

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

Am I the only one who thinks problems like F are not very interesting? They are very guessable (I was very disappointed to find out that my random hunch about what the answer might be was entirely correct) and reduce to a small number of pretty typical greedy arguments. Although it is an ad-hoc problem (which can be promising), it still is not a very interesting problem to solve.

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

    What's your "easily guessable" hunch? I spent like at least half an hour in contest thinking of all the ways to get rid of dominant segment endings, before realising that most of them were no better than shoving them somewhere inside another segment and forgetting about them.

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

    well i think it shouldnt be the F problem. and also yes i think the hard part of the solution was to actually build the answer. if the problem wants the actual permutation it could be nice problem for F in my opinion.

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

      I don't know, that might be a quite painful implementation. But it would definitely redeem the guessability (and maybe the problem).

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

I Hate the Tic-Tac-Toe grid
UPD: after see the editorial., i understood that was a good learning problem. but c & d can be replace their place.

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

Interesting problem set, but I solved C1 and C2 in a very similar way to this problem

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

    I thought of that problem but could't find the relation, can you elaborate?

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

      Sure! In the other problem, you increase the numbers based on the parity of the sum i + j. In C1, you can do the same, but only for positions (i, j) that have (i + j) % 3 = 0. This does work, but sometimes can go over k / 3. So you can check all remainders and try to flip all position (i, j) that have (i + j) % 3 = r. C2 is very similar, I'll let you figure it out.

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

    Thanks for the reference, I also remember the similar problem but could not find it.

»
3 года назад, # |
  Проголосовать: нравится -7 Проголосовать: не нравится

C1 and C2 spoiled this contest for me :-(

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

What the hell was up with this problem $$$C$$$ this time, huh?!
It has become hard these days to find a contest which feels fine in terms of difficulty distribution.

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

I loved the problemset, especially E was very interesting (for me, I have never seen such a reduction to shortest path before).

However, the contest was also very demoralising as I watch myself struggle to solve something more than a thousand people could do :(

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

Toughness == Trickyness

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

How do you solve C1?

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

That difficulty jump between B and C1 tho D:

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

Why not just call this a Division 1? Sucks when you bait contestants with a trivial A, and then bump up the difficulty level significantly (C appears to be insanely difficult). Oh well.

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

Me after coding all kinds of stupid stuff for C for 2 hours clown

»
3 года назад, # |
  Проголосовать: нравится -6 Проголосовать: не нравится

Does greedily converting 'X' which provides most number of winning configs work in C1?

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

C2 was really beautiful.

Hint for those who are stuck:
  • »
    »
    3 года назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Used that for C1, couldn't prove that it'd work for C2. How to do that? I'm struck in this area.
    Color $$$0$$$ -> $$$2$$$ X, $$$2$$$ O, Color $$$1$$$ -> $$$2$$$ X, $$$2$$$ O, Color $$$2$$$ -> $$$2$$$ X, $$$2$$$ O

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

      Make sure that no cell with colour 1 contains a X, and no cell with colour 2 contains an O (or colours 2 and 3, or 3 and 1, with whichever one you need the least swaps).

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

During this contest, I proved strictly more than one of my solutions by stating "This sounds very elegant and passes pretests, QED".

»
3 года назад, # |
  Проголосовать: нравится -6 Проголосовать: не нравится

I wish Lenin could participate in this round... Problem E ٩(╬ʘ益ʘ╬)۶

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

So, what did "antontrygubO_o for inspiration!" mean? I assumed some ideas for some problems ideas had come from antontrygubO_o, which is tiny (but nonzero) information, but I was kind of confused when I saw the standings showing that name.

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

Pretest seems to be made very strong by the preparers! Thanks!

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

I guess this contest is made only for Legendary Grandmasters. Difficulty level at its peak!

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

The hardest Tic-Tac-Toe ever

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

Tic-Damn-Toe

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

Any heuristic which passed C1/C2 (different from editorial)?

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

Problem D

If number of occurrences of some number (let's call it i) is 0 then all compressions for all k=1...n-i+1 aren't permutations

If number of occurrences of i more than 1 then all compressions for all k=1...n-i aren't permutations

If there are numbers to the left and to the right of i that both greater than i then all compressions for all k=2...n-i aren't permutations. For this checking do the cycle and keep l and r — left and right bounds of subsegment of array that is not considered yet. If position of current i is not equal to l+1 or r-1 then break the cycle. Else move the left or right bound.

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

    I used binary search + segment tree. have a look 100580701

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

      I didn't complete my implementation yet, but with sparse table it can be done even simpler and faster. Still using binary search of course.

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

      This is just 2-3 simple cycles, O(n)

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

    Coincides with my solution

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

As a contestant I want rating++

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

.

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

where r the rating changes XD

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

Have a look at those videos.A person uploaded videos during the contest... A- youtube.com/watch?v=oKA9mzrEkJU&ab_channel=AbhinavKumar B- https://www.youtube.com/watch?v=PyBte0lSc6I&t=73s&ab_channel=AbhinavKumar

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

It is a draw!

Capture187771b7393dba12.png

Spoiler

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

D saved this contest for me, phew.

»
3 года назад, # |
Rev. 3   Проголосовать: нравится 0 Проголосовать: не нравится
for C1 why this code is giving wrong ans
  • »
    »
    3 года назад, # ^ |
      Проголосовать: нравится +1 Проголосовать: не нравится

    I'm not sure , but in ~~~~~ if(cnt1<cnt2 and cnt1<cnt3) for(int i=0;i<n;i++) cout<<tvec1[i]<<endl; else if(cnt2<cnt1 and cnt2<cnt3) for(int i=0;i<n;i++) cout<<tvec2[i]<<endl; else for(int i=0;i<n;i++) cout<<tvec3[i]<<endl; ~~~~~ your ifs are wrong , because there is a possibility that cnt1 == cnt2 and cnt1 < cnt3 but your code will use 3 , while he should use 1 or 2.

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

    Idk where is the mistake, I was just curious whether I can find a WA in less than three attempts. Here is my very first attempt lol :D

    test
»
3 года назад, # |
  Проголосовать: нравится +27 Проголосовать: не нравится
»
3 года назад, # |
  Проголосовать: нравится +71 Проголосовать: не нравится

Congratulations to the t-shirt winners!

List place Contest Rank Name
1 1450 1 Benq
2 1450 2 tourist
3 1450 3 jiangly
4 1450 4 IZONE
5 1450 5 ecnerwala
6 1450 6 Um_nik
7 1450 7 ksun48
8 1450 8 244mhq
9 1450 9 maroonrk
10 1450 10 yosupo
11 1450 11 snuke
12 1450 12 atomicenergy
13 1450 13 Rebelz
14 1450 14 tatyam
15 1450 15 Swistakk
16 1450 16 Egor
17 1450 17 hos.lyric
18 1450 18 kort0n
19 1450 19 sunset
20 1450 20 majk
21 1450 21 antontrygubO_o
22 1450 22 ugly2333
23 1450 23 Maksim1744
24 1450 24 stevenkplus
25 1450 25 hitonanode
26 1450 26 Amoo_Safar
27 1450 27 LayCurse
28 1450 28 _h_
29 1450 29 TeaPot
30 1450 30 KAN
32 1450 32 Golovanov399
85 1450 85 Savior-of-Cross
92 1450 92 sstrong
116 1450 116 Series_205
131 1450 131 Jimanbanashi
150 1450 150 Qing_Yang
155 1450 155 emorgan
184 1450 184 cuom1999
205 1450 204 goodbaton
218 1450 218 gangpenwang
239 1450 239 bekzhan29
249 1450 249 201831990439
290 1450 290 Ujimatsu
293 1450 293 AnotherRound
307 1450 307 Farhod
314 1450 314 BSBandme
327 1450 327 aytel
412 1450 412 arbuzick
414 1450 414 kalimm
415 1450 415 matt64