The active prefix of the array must represent a complete -ary tree, filled in the prescribed order, and must obey heap order:Equivalently, every parent is no larger than each existing child. Repeatedly following parents shows that the root contains a global minimum. The array representation already provides the complete-tree shape; it is not enough to check only that the root is a minimum, since the inequality must hold throughout the d-ary min-heap. Assume integral throughout the heap operations.
Articles by others on the same topic
There are currently no matching articles.