filmov
tv
Insertion Sort
Показать описание
In this video we are going to use the insertion sort algorithm to sort a list of 5 numbers in ascending order. The insertion sort algorithm works by taking each value in the list and comparing it to all previous values in the list until the value finds it's appropriate position in the sorted list. This occurs once the value is compared to a previous value in the list it is not less than. At this point the value will be placed immediately after the value in which it was not less than. This continues until the list is sorted.