Selection sort algorithm created.