User Input And While Loops

7-1. Rental Car: Write a program that asks the user what kind of rental car they

would like. Print a message about that car, such as “Let me see if I can find you

a Subaru.”

7-2. Restaurant Seating: Write a program that asks the user how many people

are in their dinner group. If the answer is more than eight, print a message saying

they’ll have to wait for a table. Otherwise, report that their table is ready.

7-3. Multiples of Ten: Ask the user for a number, and then report whether the

number is a multiple of 10 or not.

7-5. Movie Tickets: A movie theater charges different ticket prices depending on

a person’s age. If a person is under the age of 3, the ticket is free; if they are

between 3 and 12, the ticket is $10; and if they are over age 12, the ticket is

$15. Write a loop in which you ask users their age, and then tell them the cost

of their movie ticket.

7-7. Infinity: Write a loop that never ends, and run it. (To end the loop, press

ctrl-C or close the window displaying the output.)

7-8. Deli: Make a list called sandwich_orders and fill it with the names of various

sandwiches. Then make an empty list called finished_sandwiches. Loop

through the list of sandwich orders and print a message for each order, such

as I made your tuna sandwich. As each sandwich is made, move it to the list

of finished sandwiches. After all the sandwiches have been made, print a

message listing each sandwich that was made.

7-9. No Pastrami: Using the list sandwich_orders from Exercise 7-8, make sure

the sandwich ‘pastrami’ appears in the list at least three times. Add code

near the beginning of your program to print a message saying the deli has

run out of pastrami, and then use a while loop to remove all occurrences of

‘pastrami’ from sandwich_orders. Make sure no pastrami sandwiches end up

in finished_sandwiches.

(in the attachment you will find the book with their exercises. it is in chapter 7 )

THank you

Place this order or similar order and get an amazing discount. USE Discount code “GET20” for 20% discount