binary search, becareful with index.