Vous êtes sur la page 1sur 1

Quicksort

The best and average case is nlgn.


Worst case is n^2. It happen when pivot is at the left or right end of the array
without dividing it.

Heapsort

The parent node cannot be 0 as we need it later to calculate.


Tree is complete at least through depth h-1. Meaning at h-1 all have 2 child.

Vous aimerez peut-être aussi