Step 1/0
Complexity
Best:O(1)
Average:O(log n)
Worst:O(log n)
Space:O(n)
Description
A complete binary tree where every parent node is smaller than its children. The root is always the minimum element.
When to use
Priority queues, Dijkstra's algorithm, heap sort, scheduling systems. O(log n) insert and O(1) min access.