Which of the following is true? Select one: a sequential search of a list requir
ID: 3582629 • Letter: W
Question
Which of the following is true?
Select one:
a sequential search of a list requires the list already be sorted
a binary search of a list requires the list already be sorted
both sequential and binary searches requires the list already be sorted
none of the above
Question 33
Which of the following growth-rates grows the slowest (meaning it has the best efficiency)?
Select one:
O(1)
O(n )
O(n3)
O(2n)
O(n log n)
Question 34
Which of the following growth-rates grows the fastest (meaning it has the worst efficiency)?
Select one:
O(1)
O(n log n)
O(n3)
O(2n)
O(n )
Explanation / Answer
Answers:a binary search of a list requires the list already be sorted
Explanation:As it check whether the element is greater than middle element of the list or smaller and then search accordingly.
Ans33)O(1)
Ans34)O(n3)
Note:Please do ask in case of any doubt,thanks!!
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.