midSorting
What is Heap Sort?
Updated Apr 28, 2026
Short answer
Using a Binary Heap data structure to find the maximum element and repeatedly extract it.
Deep explanation
Intermediate sorting algorithms focus on O(n log n) efficiency and specialized constraints. Using a Binary Heap data structure to find the maximum element and repeatedly extract it.
Real-world example
Standard library sort implementations (e.g., Python's Timsort).
Common mistakes
- Forgetting that Merge Sort requires O(n) extra space.
Follow-up questions
- Is Quick Sort stable?
- Time complexity of Heap Sort?