Question: How do you do this? I have tried different ways but still unable to get the answer. Python please, thanks. Consider the following description of
How do you do this? I have tried different ways but still unable to get the answer. Python please, thanks.

Consider the following description of the Selection Sort algorithm. Write a function named selection_sort_descending (numbers) which takes a list of integers as its parameter and sorts the list in descending order. Selection Sort is a simple sorting algorithm. This sorting algorithm is an in-place comparison-based algorithm in which the list is divided into two parts, the sorted part at the right end and the unsorted part at the left end. Initially, the sorted part is empty and the unsorted part is the entire list. To sort in descending order, the smallest element is selected from the unsorted part of the list and swapped with the rightmost element, and that element becomes a part of the sorted array. This process continues moving the boundary of the unsorted list by one element to the left. Note: To solve this question you are not allowed to use the Python methods reverse() or reversed) or the slicing trick "[:-1]" anywhere in your solution. You also are not allowed to use Python's built in sort() or sorted() functions. For example: Test Result [16, 11, 7, 2, 1] numbers = [2, 16, 7, 11, 1] selection_sort_descending (numbers) print(numbers)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
