Question DSA-CX-0051
MediumAn algorithm takes 3 seconds for n = 1,000 and 24 seconds for n = 2,000. What is its likely complexity?
- A.
O(n³)
- B.
O(2ⁿ)
- 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
Complexity Analysis question
An algorithm takes 3 seconds for n = 1,000 and 24 seconds for n = 2,000. What is its likely complexity?
O(n³)
O(2ⁿ)
Sign up free to see the answer and a step-by-step explanation.
O(n log n)
O(n²)