java实现的二分查找法
static public int search(int [] array, int target) { int high = array.length, low = -1, probe; while (high - low > 1) { probe = (low + high) >>> 1; if (array[probe] < target) low = probe; else high = probe; } if (high == array.length || array[high] != target) return -1; else return high; }