Question: Prompt the User for Input: Ask the user to enter their name. Ask the user to enter their favorite color. Ask the user to enter
Prompt the User for Input:
Ask the user to enter their name.
Ask the user to enter their favorite color.
Ask the user to enter their age.
Ask the user to enter a number between and
Process the Input:
Store each piece of information in a variable.
Ensure the age and the number are integers.
Validate that the number is between and using a loop.
Convert the favorite color to uppercase.
Perform Calculations:
Add to the number provided by the user.
If the user's age is an even number, multiply the result by
If the user's age is an odd number, subtract from the result.
Display the Information:
Print a summary that includes all the information provided by the user.
Display the favorite color in uppercase.
Display the result of the calculations.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
