Which one is faster?
A binary search of an orderd set of elements in an array
or
a sequential search of the elements.
Answer Posted / p.divya poojitha
binary search is faster than sequential searching.in
sequential searching the desired record is 4000 if u search
that record can be done with 1....4000 so it takes large
time for searching compare complexities of both searching
meathods are
binary search O(logn)
sequential search O(n)
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How do you find the complexity of a selection sort?
Why is treeset sorted?
How to use appendNode() in linkedlist()?
Should I use hashmap or hashtable?
What is link list in data structure?
Can treeset contain duplicates?
What is a pass in bubble sort?
What are the drawbacks of array implementation of queue?
Differentiate between queue and stack.
Is quicksort greedy algorithm?
How can someone display singly linked list from first to last?
What is difference between array and string?
What is the minimum number of nodes that a binary tree can have?
What thread means?
What does isempty() member method determines?