Question DSA-ARR-0068
HardWhat is the time complexity of finding the median of an unsorted array with the median-of-medians algorithm?
- A.
O(n) worst case
- B.
O(n log n)
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Arrays question
What is the time complexity of finding the median of an unsorted array with the median-of-medians algorithm?
O(n) worst case
O(n log n)
Sign up free to see the answer and a step-by-step explanation.
O(n²)
O(log n)