abcdqwerty12345's blog

By abcdqwerty12345, history, 3 years ago, In English

Hello everyone! This is my code for submission of this problem that occured in today's Div-3 contest

Here the judgement for the case 31 of test-case 2 says:- wrong answer Exceeded limit of person 8 on step 4 (test case 31)

The test case 31 is

10

4 1 0 1 1 1 0 2 1 0

My code is giving the following output:-

5

8 1

8 1

9 1

6 1

4 9

I could not find any error in the answer. Person 8 has 2 sociability .Hence can appear in at-most 2 times.Where is the issue then??

Thanks in advance !!!

  • Vote: I like it
  • -10
  • Vote: I do not like it

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

why your code is using 9 two times? I think your code is incorrect, you can use priority_queue or something else to solve this question.