binary search on an array giving errors : So I'm doing a binary search on an array. But somethings to be off. It returns -1 as if the target is not being found but it is in the array. 
ex: when i put the key at 555 it returns the correct index but when i try with the example below with 8 it returns -1..

    public class bSearch {
    
    	public static void main(String[] args) {
    		int[] nums = {9,5,2,5,7,8,3,22,555};
    		int key = 8;
    		
    		System.out.println(searchForNum(nums,0,nums.length-1,key));
    		
    	}
    	  private static int searchForNum(int[] arr,int first, int last, final int target) {
    		  
    		 
    		  int middle= (first+last)/2;
    		  
    		  if(last < first) {
    			  return -1;
    		  }
    		 
    			 if(arr[middle]== target)
    				 return middle;
    			 else if(target < arr[middle]) {
    				 return searchForNum(arr,first,middle-1,target);
    			 }else {
    				 return searchForNum(arr,middle+1,last,target);
    			 }
    		 
    		  
    	  }
    	
    
    }