Binary Heap Question interpretation

42 Views Asked by At

In the question in the link below, how do I tell weather to draw out a binary min heap or a binary max heap? Am I misunderstanding the question?

Binary Heap Question

1

There are 1 best solutions below

0
On

In this special case the question might be assuming you know about the in-place binary heap structure using an array where the $k$-th element is the parent of the $(2k)$-th and $(2k+1)$-th elements. Why on earth it's called a heap I don't know.