Heapsort uses a max-heap (or a min-heap for sorting in descending order) in order to sort