Valintalajitteluohjelman suoritusaika
Käännetään ja suoritetaan edellinen ohjelma:
tukki% cc -o selectsort.out selectsort.c
Generating 1000 random numbers in the range 0..32767.
Beginning selection sort of 1000 items
Done. Time = 0.04 seconds.
Generating 2000 random numbers in the range 0..32767.
Beginning selection sort of 2000 items
Done. Time = 0.16 seconds.
Generating 3000 random numbers in the range 0..32767.
Beginning selection sort of 3000 items
Done. Time = 0.36 seconds.
Generating 10000 random numbers in the range 0..32767.
Beginning selection sort of 10000 items
Done. Time = 4.14 seconds.