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?
My solution: CodeChef: Practical coding for everyone
tmw’s AC solution: CodeChef: Practical coding for everyone