Question: Write a function called createList that will create and fill a list of any size with random numbers in the range of 1 - 100.

Write a function called createList that will create and fill a list of any size with random numbers in the range of 1 - 100. This function should take the size of the list as a parameter to the function. It should return the created list.

Write a separate function called printList that will print a list of any size. This function should take the list to print as an argument.

Write a third function called smallLarge which will search a list given to it and return back the smallest and largest value in the list. You will need to use a tuple to return multiple items. This function should take the list to search as an argument.

In the main part of your program do the following

Fill the list with 25 numbers using the createList function

Print the List using the printList function

Print the largest and smallest values in the array. Use the smallLarge function to get determine the small and large values.

What not to do

global variables

input in any funciton

print in any funciton other than main and printList

Your output should look like the following:

Write a function called createList that will create and fill a list

C:WINDOWS system32\cmd.exe 36 35 35 60 19 79 6 94 47 23 61 16 72 63 24 56 61 38 56 72 70 75 The smallest number is e The largest number is 94 Press any key to continue

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!