The element being searched for is not found in an array of
100 elements. What is the average number of comparisons
needed in a sequential search to determine that the element
is not there, if the elements are completely unordered?
Answer Posted / shailesh pratapwar
The avrage case complexity of any linear search alogrithm is
n/2.
So we need 50 comparisons to search in 100 elements.
Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
Which is faster array or arraylist?
Define disjoint set adt?
Can treemap have duplicate values?
How can avl tree be useful in all the operations as compared to binary search tree?
What is heap with example?
How can I learn data structures?
How can you correct these errors?
Explain singly linked list in short.
What are the advantages and disadvantages of linked list over array?
How do you sort in ascending order in arraylist?
What is bubble insertion selection sort?
Can arraylist contain duplicates?
What is data structure and its operations?
How can you represent a linked list node?
What are examples of data structures?