Question: Lab Assignment For this lab you will write the following 4 functions and a main: getInput ) This function should take no parameters and return

 Lab Assignment For this lab you will write the following 4functions and a main: getInput ) This function should take no parametersand return the following four values read from user input in the

Lab Assignment For this lab you will write the following 4 functions and a main: getInput ) This function should take no parameters and return the following four values read from user input in the order listed below. Input a color. Input a number. Input a second number Input a season. The prompts for these inputs can be whatever you'd like printcolor This function should take 1 parameter and return nothing. It should print out the sentence "Favorite color is parameter where parameter is the color passed to the function. addNumbers ) This function should take 2 number parameters and return their sum. setGlobal) This function should take 1 parameter and return nothing. This function should set the global variable favoriteseason to the value of the parameter main() This function should take no parameters and return nothing. This function should first call getlnput0 and unpack the four resulting variables. It should then call printColor with the first unpacked value. Then call addNumbers with the float of the second and third unpacked value. Then call setGlobal with the fourth unpacked value. main.py 1 favoriteSeason 3 if-name__== '-main-' : 4mainO

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!