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 / dj

Answer is log n (base 2), Maximum camparision required to
search the array of 100 elments is 8. ( modified binary
search)

Is This Answer Correct ?    10 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the Insertion Sort Code?.

627


What is complexity of quicksort?

516


What do you mean by balanced trees?

541


What is raid (redundant array of inexpensive disks)?

538


What is weight balanced tree in data structure?

474






Can arraylist have duplicates?

520


Which is faster binary or linear search?

481


How to inverting a function in sort and searching?

472


What are the applications of graph data structure?

474


Why do we use sorting?

468


How memory is reserved using a declaration statement ?

656


Does mentioning the array name gives the base address in all the contexts?

773


Define dynamic data structures?

546


What are the scenarios in which an element can be inserted into the circular queue?

893


What is linear and non linear structure?

490