Kingdom of Crisis

In a kingdom far away, $N$ people live in a circle of harmony. Literally, they have constructed a ci…

Click here to read the complete problem statement.


If you need help solving this problem, mention your approach and ask specific questions. Please avoid sharing your code and asking the Community to figure out “what’s wrong”.

I think something is wrong with the Test Case 22 of the dataset. When I add assert in my accepted code, the assertion failed & it got RTE in Test Case 22. I’ve applied assert in this way:

string s; cin >> s;
assert(s.length() == 0);

My deduction is, there are extra characters that remained in that specific test case file. Can you please look into this issue? Here are the submissions of mine:

Accepted Submission: https://toph.co/s/654348

RTE with Assert: https://toph.co/s/654726

1 Like

@shefin Looks like test case 22 and 23 were missing N at the beginning. Your source code with assert should now pass.

Yes, assert is passing now. Thank you.

1 Like