public int find(int value){
int lowpperBound=0;
int upperBound=list.size;
int curIn=0;
while(true){
curIn=(lowpperBound+upperBound)/2;
if(lowpperBound>upperBound)
break;
else if(list[curIn]==value)
break;
else if(list[curIn]>value)
upperBound=curIn-1;
else
lowpperBound=curIn+1;
return curIn;
}