...

/

Solution Review: Convert Max-Heap to Min-Heap

Solution Review: Convert Max-Heap to Min-Heap

Let’s solve the Convert Max Heap to Min Heap problem.

Statement

Given a list representing a max heap, convert this into a min heap.

Constraints:

  • 00\leq max_heap.length 102\leq 10^2

  • 104-10^4\leq ...