Computer Applications
A binary search of elements in an array requires that the elements be sorted from smallest to largest. True or False ?
Java Arrays
2 Likes
Answer
False
Reason — A binary search requires a sorted array. It may be in ascending order or descending order.
Answered By
3 Likes
Related Questions
What are the preconditions for Binary Search to be performed on a single dimensional array ?
A binary search of an ordered set of elements in an array is always faster than a sequential search of the elements. True or False ?
The performance of linear search remains unaffected if an unordered array is sorted in ascending order. True or False ?
For inserting of an element in a sorted array, the elements are always shifted to make room for the new entrant. True or False ?