Discover the answers you need at Westonci.ca, a dynamic Q&A platform where knowledge is shared freely by a community of experts. Discover in-depth solutions to your questions from a wide range of experts on our user-friendly Q&A platform. Get detailed and accurate answers to your questions from a dedicated community of experts on our Q&A platform.

What is the maximum number of comparisons that a binary search should do for a sorted array of 81,014 elements ?

Sagot :

The maximum number of comparison is 4502

Binary array : it is an array consist of only 0s and 1s only.

Binary search - an efficient algorithm for finding items from a sorted list.

it is called binary because it divide array into tow halves.

It is used to excess data more faster when the space is tight.

binary search will search the array by dividing it into two halves till it find the value.

The main advantage of it is that is more quicker than a serial search.

binary search algorithm can be implemented in the two ways :

1. Iteration method

2. Recursive method

the maximum number of comparisons is 4502.

To know more about binary array :

https://brainly.com/question/28346440

#SPJ4