Question: design a program that prompts the user for and reads in certain information that will be used to display a short narrative! You must create
design a program that prompts the user for and reads in certain information that will be used to display a short narrative! You must create the program using the script mode
1. Your program must include a description to the reader.
""" file prog1.py CAIS 001 This program uses the input() function to read from the keyboard information about a student into variables. The program then uses this information and a print() function to send a narrative about the student to the screen. """
2. Your program must provide a description of the program to the user. You should use a print() function and display at the screen something like this: This program prompts for and reads from the keyboard specific information about you. It then displays a narrative about you at the screen.
3. Your program must read the following information from the keyboard into the following variables described below: Name This is the preferred first name of the user Year This is the anticipated year of graduation Color This is the favorite color of the user popStar This is the users favorite music pop star Food This is the users favorite food to eat dreamCar This is the users favorite dream car to buy occupation This is the occupation being pursued by the student salary This is the anticipated starting salary on the first job The variables Name, Color, popStar, Food, dreamCar, and occupation are to be read in as strings. The variable, Year, is to be read in as integer. The variable, salary, is to be read in as float 2
4. The program must use these variables and print() functions to display at the screen the following narrative. The following notation indicates where your program should provide the values of the corresponding variable. Hello everyone! My name is . I am a student enrolled at Westfield State University. My anticipated year of graduation is . My favorite color is . I really enjoy listening to my favorite entertainer, ! My favorite food to eat is . When I graduate and become a , I hope to earn a starting salary of $! Then, I hope to buy my dream car, a !! I hope that you have enjoyed learning about me!
5. Make sure that salary is formatted including commas and two digits to the right of the decimal point!
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
