Computer Science, asked by TbiaSamishta, 1 year ago

In binary search , which will be the scenario for best case performance ? the middle element is equal to the target element o(2) the middle element is equal to the target element o(1) the middle element is equal to the target element o(4) the middle element is equal to the target element o(3)

Answers

Answered by Sidyandex
0

Binary search is applied in a sorted array.

The best case scenario of binary search occurs when you are searching for the element is the middle element of the list/array.

In such case, you will get the desired result in a single go without any delay.

It always takes constant amount of time as 0(1).

Similar questions