answersLogoWhite

0


Best Answer

You will find one of them (not necessarily the first or the last).

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What if the elements are repeated in binary search?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Is it true In a binary search if the search fails to find the item on the first attempt then there are 999 elements left to search in an array of 1000 elements?

False. In a binary search, if the search fails on the first trial of an array of 1000 elements, then there are only nine more elements left to search.


A binary search of an orderd set of elements in an array or a sequential search of the elements.Which one is faster?

A binary search is much faster.


Can you use binary search on linked list elements?

No.


When binary search can't be implemented?

When the elements... ... are not sorted ... have different sizes ... are only sequentially accessible


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

binary search system


What are the Advantages of binary search on linear search in c?

(i) Binary search can interact poorly with the memory hierarchy (i.e. caching), because of its random-access nature. For in-memory searching, if the interval to be searching is small, a linear search may have superior performance simply because it exhibits better locality of reference. (ii) Binary search algorithm employs recursive approach and this approach requires more stack space. (iii) Programming binary search algorithm is very difficult and error prone (Kruse, 1999).


Why binary search is used for the large values of arrays?

Binary search is used for large arrays because it is the fastest search, on the order of O-Log2-N complexity, which means that the maximum number of compare operations to find a specific item is Log2N, where N is the number of elements.


What repeated elements do you detect in The Alarm Clock?

what repeated elements can you detect in the alarm clock


Mendeleev's pattern repeated after how many elements?

The properties were repeated after 8 elements.


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

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


Are binary molecular compounds made of metallic elements or nonmetallic elements?

Binary molecular compounds are composed of two nonmetallic elements.


What is the binary search tree worst case time complexity?

Binary search is a log n type of search, because the number of operations required to find an element is proportional to the log base 2 of the number of elements. This is because binary search is a successive halving operation, where each step cuts the number of choices in half. This is a log base 2 sequence.