×

Multiple-Choice Questions

Web Technologies MCQs

Computer Science Subjects MCQs

Databases MCQs

Programming MCQs

Testing Software MCQs

Digital Marketing Subjects MCQs

Cloud Computing Softwares MCQs

AI/ML Subjects MCQs

Engineering Subjects MCQs

Office Related Programs MCQs

Management MCQs

More

Which of the following correctly defines the worst-case time complexity of Linear Search Algorithm?

3. Which of the following correctly defines the worst-case time complexity of Linear Search Algorithm?

  1. O(n)
  2. O(1)
  3. O(nlogn)
  4. O(n2)

Answer

The correct answer is: A) O(n)

Explanation

Linear Search, searches an element sequentially in a list. In the worst case, where an element is not present, the linear search algorithm has to scan all elements leading to O(n).

Comments and Discussions!

Load comments ↻






Copyright © 2024 www.includehelp.com. All rights reserved.