To understand how Selection sort works you can use this java applet code.
Redbar:-Value that going to compared with other values.
Bluebar:-The minimum value for current iteration and after iteration the value is exhanged with redbar's value.
Greenbar:-The value that going to compared with redbar's value