answersLogoWhite

0


Best Answer

n log n - G.Parthiban, SRM

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: The order of binary search algorithm is?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Which search algorithm requires that the arrays contents be sorted?

Binary Search Algorithm


How do you print all data in a Binary Search Tree?

By using Depth First Search or Breadth First search Tree traversal algorithm we can print data in Binary search tree.


Why binary search algorithm did not work on an unsorted array?

The binary search algorithm works by successively halving the array and determining which half the result lies in, or if the half-way point is the result. In order for that to work, the array must be in order, otherwise choosing the half-way point would be meaningless because it would not tell you which half of the array the result is located in.


Give you the algorithm of creating a new binary search tree using c?

i want to know how to give the algorithm password in a computer ?


How can one perform a binary search?

One can perform a binary search easily in many different ways. One can perform a binary search by using an algorithm specifically designed to test the input key value with the value of the middle element.


How do you do binary search in file?

A binary search on a random-access file is performed much in the same way as a binary search in memory is performed, with the exception that instead of pointers to items in memory file seek operations are used to locate individual items within the file, then load into memory for further examination. The key aspects of the binary search algorithm do not depend on the specifics of the set of searchable items: the set is expected to be sorted, and it must be possible to determine an order between any two items A and B. Finally, the binary search algorithm requires that the set of searchable items is finite in size, and of a known size.


What assumption about the list is made when binary search is conducted?

Binary search requires that the list be in search key order.


Which are the searching algorithm always compare the middle element with the searching elements in the given array?

binary search system


What search algorithm locates an item in an array by repeatedly dividing the array in half?

half means 1/2 from the whole (previous), which means 2 of 1/2, and 2 derived into binary. Ha, Binary Search is the term.


Items that are not suitable for a binary search?

The only items suitable for a binary search are those which are in a sorted order.


When is it not recommended to perform the operation of binary search?

In computer science, a binary search or half-interval search algorithm finds the position of a specified value (the input "key") in an array sorted[1][2] into order on the values of the key. At each stage, the algorithm compares the sought key value with the key value of the middle element of the array. If the keys match, then a matching element has been found so its index is returned. Otherwise, if the sought key is less than the middle element's key, then the algorithm repeats its action on the subarray to the left of the middle element or, if the input key is greater, on the subarray to the right. If the array span to be searched is reduced to zero, then the key cannot be found in the array and a special "Not found" indication is returned.A binary search halves the number of items to check with each iteration, so locating the an item (or determining its absence) takes logarithmic time. A binary search is a dichotomic divide and conquer search algorithm.Next AnswerA binary search method requires that the list of items being search should be sorted in ascending (or descending) order. If the search list is not sorted, the binary search method will not work and other search methods will be needed.


Prove by mathematical induction that the complexity of binary search algorithm is log n?

The complexity of the binary search algorithm is log(n)...If you have n items to search, you iteratively pick the middle item and compare it to the search term. Based on that comparision, you then halve the search space and try again. The number of times that you can halve the search space is the same as log2n. This is why we say that binary search is complexity log(n).We drop the base 2, on the assumption that all methods will have a similar base, and we are really just comparing on the same basis, i.e. apples against apples, so to speak.