answersLogoWhite

0


Best Answer

1. direct access to the elements

2. the elements are sorted

User Avatar

Wiki User

12y ago

Still curious? Ask our experts.

Chat with our AI personalities

ReneRene
Change my mind. I dare you.
Chat with Rene
FranFran
I've made my fair share of mistakes, and if I can help you avoid a few, I'd sure like to try.
Chat with Fran
CoachCoach
Success isn't just about winning—it's about vision, patience, and playing the long game.
Chat with Coach
More answers
User Avatar

Wiki User

11y ago

This question has already been asked on this site. Quite a few times actually.

User Avatar

User Avatar

Anonymous

Lvl 1
4y ago

element should be in sorted order

User Avatar

Add your answer:

Earn +20 pts
Q: What is required in order to perform a binary search?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How can you merge two binary search trees into a single binary search tree?

To merge two binary search trees into a single binary search tree, you can perform an in-order traversal on each tree to extract their elements, combine the elements into a single sorted list, and then construct a new binary search tree from the sorted list. This process ensures that the resulting tree maintains the binary search tree property.


What is the purpose of performing a binary search tree inorder traversal?

Performing a binary search tree inorder traversal helps to visit all nodes in the tree in ascending order, making it easier to search for specific values or perform operations like sorting and printing the elements in a sorted order.


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

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


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.


Is sorting a binary search tree simple?

A binary search tree is already ordered. An in order traversal will give you a sorted list of nodes.


What is complexity of binary search tree?

The complexity of binary search tree : Search , Insertion and Deletion is O(h) . and the Height can be of O(n) ( if the tree is a skew tree). For Balanced Binary Trees , the Order is O(log n).


It is pre requisite for binary search that the list should be in sorted order but if you have a unsorted list then which searching technique would be better binary search or linear search?

4 more info search how dangerous is the swine flu


The order of binary search algorithm is?

n log n - G.Parthiban, SRM


How many verification steps are required in order to perform a phone money transfer?

There are many steps that are required in order to perform a phone money transfer. There are exactly nine steps which are required to be able to do so.


What role does knowledge of data organization have in information retrieval?

Knowledge of how information is organized will allow a programmer to make more informed decisions on how to retrieve information. A simple example of this is the binary search. If you're looking for information in a list of data, you would normally need to perform an inefficient O(n) linear search. But if you happen to know that the data will always be in sorted order, you can use a nice O(log n) binary search instead.


Which of the following traversal is used for printing the keys of binary search tree in ascending order?

In order traversal is used.


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.