Multiple choice

In binary search algorithm, consider the case if(ele < a[Mid]). Which of the following conditions is applicable?

  1. High=Mid-1

  2. Low=Mid+1

  3. High=Mid+1

  4. High=Low-1

  5. Low=High

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

This is the correct condition as if element is lesser than a[Mid], then the required element is available in the first half of the list.