Hello, I saw @tmwilliamlin 's editorial, and then wrote this solution. This solution is exactly like his, but i am getting WA. Can someone please help me identify what the problem is?
return your program doesn’t answer the rest of the test cases.
Corrected my mistake. Thank you so much!