What is the average number of comparisons needed in a
sequential search to determine the position of an element in
an array of 100 elements, if the elements are ordered from
largest to smallest?
Answer Posted / mohit0749
I think it we can apply binary search which requires only logn comparison becoz elements are ordered (largest to smallest).
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Write an algorithm to show the reverse of link list?
Are data structures important?
Define depth and height of a tree?
List the differences between comparable and comparator interface?
Does hashtable allow null values?
Can you sort a hashmap?
How to inverting a function in sort and searching?
Explain what is binary search?
Which is better bubble sort or selection sort?
Which interface provides the capability to store objects using a key-value pair?
Is list an array?
What are the advantages of modularity?
What is example of data?
What are control structures?
Tell me about circular linked list?