·Shift
elements in the sorted side, creating an
open space for the new element.
[0][1][2][3][4][5]
Insertion Sort
...like this.
Is this the
correct spot for the new element?No,
because the new element is smaller than the next element in the sorted
section. So we continue shifting elements rightward...