Skip to content
Sign in
Computer MOD

What is the space complexity of the merge sort algorithm?

Tap an option to check the answer. You can also press A–D.

Explanation
Merge Sort requires extra memory to merge sorted subarrays.It is not an in-place algorithm.Therefore, its space complexity is O(n) for an array of size n.Additional information: Time complexity (Best) → O(n log n)Time complexity (Average) → O(n log n)Time complexity (Worst) → O(n log n)Recursion stack → O(log n)Last verified on 24-03-2026