What if the input test case is "2 versions
2 is the first bad version."?
Actually your program only call the API once but you return twice. Can you explain why?
The "start" is begin from 1, not zero. So if you return start directly, is it correct?
First Bad Version