Question: Please help! A comment with the lab number and purpose of this lab.. Declare a function with one parameter to create a list of X
A comment with the lab number and purpose of this lab.. Declare a function with one parameter to create a list of X elements (numbering from 1 to X) and then output this list to the screen. Declare a function with two parameters (X and Y) to create a list of X elements where the elements count by Y. For example, if X = 4 and Y = 3, you should create the following list [3,6,9,12]. You will then need to output this list to the screen. Declare a function with one parameter X that creates a list of X elements (numbering from 1 to X). You will then remove the last element of the list and print the updaed list repeatedly until only one element in the list remains. At this point you will output the remaining list (consisting of the one element) and a message saying that that is the last one. Include code in your py file to execute each of the above three functions once each. To execute each function, you should prompt the user for whatever values the function requires, then call the function with the user's values. Output a message to the user thanking them from using your program that includes your first and last name. Additional Python references: HYPERLINK "https://www.w3schools.com/python/python_lists.asp" https://www.w3schools.com/python/python lists.asp HYPERLINK "https://www.w3schools.com/python python_for_loops.asp" https://www.w3schools.com/python/python for loops.asp HYPERLINK "https://www.w3schools.com/python python_while_loops.asp" https://www.w3schools.com/python/python while_loops.asp Saving this file: Save this file as lab5_XX.py where you replace the XX with your initials. For examp
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
