Binary Search

Binary Search #

  • Often in combination with an ordered array.

  • Start with the middle element, is the searched value greater or less? Based on that we can eliminate 50% of elements. Then we move again to the middle of the remaining half. Etc…