Respuesta :
An effective approach for locating a particular item from a sorted list of elements is binary search. It works by continually dividing the section of the list that might contain the item in half, until there is only one possible position left.
What is the must required for binary search algorithm?
Sorted arrays can be used for binary search. A middle-of-the-array element and the desired value are first compared in a binary search. The position of the element in the array is returned if the target value matches the element. The lower half of the array is searched if the target value is less than the element.
To arrive at this point, I comparisons are required, where n2i=1. We get i=logn when we solve for i. Depending on how many items are in the list, the maximum number of comparisons is logarithmic. As a result, the binary search returns O. (logn).A binary search algorithm is used to locate an element in an array that has already been sorted.
To learn more about binary refer to:
https://brainly.com/question/15190740
#SPJ4