Mental Model
A max heap keeps the largest element at the top, so repeatedly removing the top gives the next largest elements.
Analogy: Imagine a pile of boxes stacked so the biggest box is always on top. Taking off the top box reveals the next biggest box underneath.
Max Heap Array Representation:
[ 9, 7, 8, 5, 6, 3, 4 ]
Heap Tree:
9
/ \
7 8
/ \ / \
5 6 3 4
ā (root is largest)