public Integer findMissing(int arr[]){
    
        int lowNum = arr[0];
        int low = 0;
        int high = arr.length -1;
        int middle = (low + high)/2;
        while(low <= high){
            middle = (low + high)/2;
            if(arr[middle] == (middle+1 + lowNum) && middle-1 >=0 && arr[middle-1] == (middle + lowNum-1)){
                return middle + lowNum;
            }
            else if((middle + lowNum) == arr[middle]){
                low = middle+1;
            }else {
                high = middle-1;
            }
        }
        return null;
    }
Find missing number in consecutive numbers.
src/com/interview/binarysearch/MissingNumberInConsecutiveNumbers.java