653. Two Sum IV - Test Case

image

With the same exact test case, when I tested, it showed that my solution gave out the correct output. However, when I submitted my code, LeetCode showed that my solution was wrong because it gave the wrong output.

I thought it kinda weird, and tried to submit again. And, still LC does not accept my solution even though the exact same test case was passed when I tested it. I am not quite sure why or what actually happens under the hood

I attach the screenshot of my solution for your reference

Comments (1)