2080 6

CSC211 · 2080 · 5 marks

Trace selection sort algorithm with array of numbers 2, 81, 6, 45, 11, 21, 23, 41, and 11.

Trace selection sort algorithm with array of numbers 2, 81, 6, 45, 11, 21, 23, 41, and 11. [5]

Data Structures and AlgorithmsChapter 6: SortingComparison Sorting AlgorithmsNumerical: selection sort trace

Array to sort (9 elements): $$[2,\ 81,\ 6,\ 45,\ 11,\ 21,\ 23,\ 41,\ 11]$$ Index 0 1 2 3 4 5 6 7 8 ----------------------------------------- Value 2 81 6 45 11 21 23 41 11 Sorting ascending. --- Method: Selection sort finds the minimum in the unsorted portion and swaps it with the first unsorted ...