Getting WA for correct Code


I have solved the problem but when I submit my code it gives wrong answer at a particular testcase and when I run that test case as custom input it gives correct results.


Same problem. check into this interview bit.


I was also facing same issue,it is possible that you have not cleared the global variables .