Binary Search

Sort by repeatedly dividing the search interval in half *Array MUST be sorted before using binary search

binarysearchgif.gif
binarysearch.gif
  • Time complexity : $O(logn)$

  • Space complexity : $O(1)$

Last updated