Question DSA-LL-0019
HardWhat is the time complexity of sorting a linked list with merge sort?
- A.
O(n log n) time and O(n) extra arrays
- B.
O(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
Linked Lists question
What is the time complexity of sorting a linked list with merge sort?
O(n log n) time and O(n) extra arrays
O(n)
Sign up free to see the answer and a step-by-step explanation.
O(n²)
O(n log n) time and O(log n) extra space for recursion