Neocortex 🧠

Search

Search IconIcon to open search

Heap Sort

Last updated Dec 21, 2021 Edit Source

Heap sort is a faster version of Insertion Sort, optimised by implementing a Heap into the Priority Queue so that the insertion and removal stages take $O(nlog(n))$ time. The insertion stage can be altered to have an $O(n)$ complexity by using Bottom-Up Heap Construction. The $O(nlog(n))$ time complexity is much more efficient than the $O(n^2)$ for insertion and selection sort (7 Important Functions).


Interactive Graph