Skip to main content

Min Heap

Learn Min Heap (Heap, Data Structures & Algorithms) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

The Min-Heap Property A min-heap is a COMPLETE binary tree where every node is ≤ both its children - the SMALLEST element is always at the root, reachable in O(1). It's typically stored as a plain array using the 2i+1 / 2i+2 / (i-1)/2 index formulas, no pointers needed.

More lessons in Heap