Question: Write a program using python to sort a given list of integer numbers (where the length of the list is not constant) in descending order

Write a program using python to sort a given list of integer numbers (where the length of the list is not constant) in descending order using for loop and a while loop.

Example Test Data:

Given List

Output

9, 10, -1, 1,0,12,3,-12,12,12

12,12,12,10,9,3,1,0,-1,-12

Step by Step Solution

3.43 Rating (159 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Heres a Python program that sorts a given list of integers in descending order using both for loop ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!