asked 73.3k views
3 votes
Given a sorted list of 1024 elements, what is the runtime for binary search if the search key is less than all elements in the list?

asked
User Stirman
by
8.6k points

1 Answer

3 votes

Answer: 1024

Linear search's runtime is proportional to the number of list elements.

answered
User Daron
by
8.0k points
Welcome to Qamnty — a place to ask, share, and grow together. Join our community and get real answers from real people.