COMPUTER SCIENCE AND ENGINEERING
DATA STRUCTURES
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
It can be used on any set of data regardless of type
|
|
It is the quickest search to use
|
|
It is a simple algorithm, so it is easy to write a computer program to carry it out
|
|
None of the above
|
Detailed explanation-1: -The biggest problem with a serial search is that it is very slow. For example, when searching through a database of everyone in the UK to find a particular name, it might be necessary to search through 60 million names before you found the one you wanted.
Detailed explanation-2: -If we know nothing about the distribution of key values, then we have just proved that binary search is the best algorithm available for searching a sorted array.
Detailed explanation-3: -Linear search can be used on both single and multidimensional array, whereas the binary search can be implemented only on the one-dimensional array. Linear search is less efficient when we consider the large data sets. Binary search is more efficient than the linear search in the case of large data sets.