@@ -0,0 +1,538 @@
+/*How to get the mid is the key point here. If we use mid = (left+right)/2, it may overflow if left%0Aand right are big numbers.*/%0A%0A%0Apublic class Solution extends VersionControl %7B%0A    public int firstBadVersion(int n) %7B%0A        int left = 1;%0A        int right = n;%0A        %0A        while(left%3C=right)%7B%0A            int mid =left +(right-left)/2;               %0A            if(isBadVersion(mid))%7B%0A                right = mid-1;%0A            %7Delse%7B%0A                left = mid+1;%0A            %7D%0A            %0A        %7D%0A        return left;%0A    %7D%0A%7D

The solution for 278