Check whether a binary tree is a max-heap

0
Remix

Decide whether a binary tree is a valid max-heap: it must be complete (checked level by level) and every node must be at least as large as its children.

MetaCodingLast asked Jul 2025
No answer yet. Write the first one; the best answer gets endorsed.