Binary Search Example with Labeled Indices yellow == low green == middle blue == high 0 1 2 3 4 5 6 7 8 -9 -2 -1 3 5 7 17 25 -9 -2 -1 3 5 7 17 25 Compare key to middle element… -9 -2 -1 3 5 7 17 25 It can’t be in the first half; eliminate first half and compare to middle of what remains -9 -2 -1 3 5 7 17 25 -9 -2 -1 3 5 7 17 Can’t be 7 or anything greater; eliminate those elements and compare again -9 -2 -1 3 5 7 17 5 is now the only thing remaining in the array. It is thus also the middle. Since the middle equals the key, we’ve successfully found our key.