Links
The sorting algorithm that shouldn’t.
(YouTube)
for i 1 to n do
for j = 1 to n do
if A[i] < A[j] then
swap A[i] and A[j]
Projects #1
View the video. Then, implement the above sort.
- Generate various list of random integers
(various list sizes)
- Duplicate and negative numbers are allowed
- Sort them with the above sort
- Print/plot performance statistics using the list
size vs execution time