Add selection sort.

This commit is contained in:
Oleksii Trekhleb 2018-04-13 07:16:55 +03:00
parent d12188980d
commit 37bbc53bf3
2 changed files with 4 additions and 2 deletions

View File

@ -6,3 +6,5 @@ the list to be sorted, compares each pair of adjacent
items and swaps them if they are in the wrong order.
The pass through the list is repeated until no swaps
are needed, which indicates that the list is sorted.
![Algorithm Visualization](https://upload.wikimedia.org/wikipedia/commons/c/c8/Bubble-sort-example-300px.gif)

View File

@ -9,6 +9,6 @@ performance advantages over more complicated algorithms
in certain situations, particularly where auxiliary
memory is limited.
![Selection Sort Visualization](https://upload.wikimedia.org/wikipedia/commons/b/b0/Selection_sort_animation.gif)
![Algorithm Visualization](https://upload.wikimedia.org/wikipedia/commons/b/b0/Selection_sort_animation.gif)
![Selection Sort Visualization](https://upload.wikimedia.org/wikipedia/commons/9/94/Selection-Sort-Animation.gif)
![Algorithm Visualization](https://upload.wikimedia.org/wikipedia/commons/9/94/Selection-Sort-Animation.gif)