what is a complexity of linear search,binery search?

Answer Posted / pratik wavhal

For Linear Search Complexity Is :- O(n).
For Binary Search Complexity Is :- O(log(at base 2)n).

Is This Answer Correct ?    8 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between one and two dimensional?

780


Treemap orders the elements on which field?

702


Define indegree of a graph?

865


What is the use of space complexity and time complexity?

766


Can we add duplicate keys in a hashmap?

664


What is data structure and data type?

740


What is the difference between linked list and array?

677


How do you find a string is anagram or not?

680


Which sorting technique is best in worst case?

671


Explain what are the methods available in storing sequential files ?

702


List the data structures which are used in hierarchical data model.

711


What do you mean by heap order property?

785


How to reverse singly link list?

702


Which is best array or linked list?

672


What are the basic operations of stack?

689