Problem statement: http://codeforces.net/contest/1155/problem/B My code: http://codeforces.net/contest/1155/submission/53187901 I am getting the wrong answer for test case 90. But the input is very big. Unable to test it. Could someone provide a small test case for which my code gets the Wrong answer? I tried for a couple of hours but failed. Thanks.