Page 1 of 1

2.15 LAB: Descending selection sort with output during execution Write a program that takes an integer list as input and

Posted: Mon Jul 11, 2022 9:51 am
by answerhappygod
2 15 Lab Descending Selection Sort With Output During Execution Write A Program That Takes An Integer List As Input And 1
2 15 Lab Descending Selection Sort With Output During Execution Write A Program That Takes An Integer List As Input And 1 (253.47 KiB) Viewed 47 times
2.15 LAB: Descending selection sort with output during execution Write a program that takes an integer list as input and sorts the list into descending order using selection sort. The program should use nested loops and output the list after each iteration of the outer loop, thus outputting the list N-1 times (where N is the size of the list). Important Coding Guidelines: • Use comments, and whitespaces around operators and assignments. • Use line breaks and indent your code. • Use naming conventions for variables, functions, methods, and more. This makes it easier to understand the code. • Write simple code and do not over complicate the logic. Code exhibits simplicity when it's well organized, logically minimal, and easily readable. Ex: If the input is: 20 10 30 40 the output is: [40, 10, 30, 201 [40, 30, 10, 201 [40, 30, 20, 10] Ex: If the input is: 783 the output is: [8, 7, 3] [8, 7, 3]