chevron_leftSorting All topics

Heap Sort

41035186

Heap sort has two acts. First it rearranges the array into a max-heap, so the biggest value is at the front. Then it repeatedly takes that biggest value and parks it at the end.

step 01/34

  • comparing
  • moving
  • in final place
  • found it

Practice

spec · json ↗