The Selectionsort Algorithm
p
The process
keeps adding
one more
number to the
sorted side.
p
The sorted side
has the smallest
numbers,
arranged from
small to large.
Sorted side
Unsorted side
[0]
[1]
[2]
[3]
[4]
[5]
Here is the array after increasing the sorted side to four elements.