java.util.Arrays中的这些方法对你或许有用
static int binarySearch(byte[] a, byte key) 
          Searches the specified array of bytes for the specified value using the binary search algorithm. 
static int binarySearch(char[] a, char key) 
          Searches the specified array of chars for the specified value using the binary search algorithm. 
static int binarySearch(double[] a, double key) 
          Searches the specified array of doubles for the specified value using the binary search algorithm. 
........其他类似