Question: By submitting this work, I assert that it is my own work and not copied from someone else or from some other source. Copied work

By submitting this work, I assert that it is my own work and not copied from someone else or from some other source. Copied work will be assigned a grade of 0 and be subject to further academic penalties at the discretion of the College. Write a Python program for the following scenario by using lists, functions, and loops.
Instructions:
Declare and initialize a 9-integer list with the name myNumbers.
During the initialization of this list, store the following numbers in it: 4,6,9,12,17,22,27,33,44.
By using the concept of loops, iterate through the elements of the list one by one and print them on the console.
Sort the list as follows:
First, move through the list and find the largest number left in the list.
Swap that number for the last element in the unsorted list.
Reduce the range of the list you are sorting by 1 and repeat steps a and b until there is only 1 element left to consider.
Print the sorted list.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock 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 Databases Questions!