Question: In python This time, we want to print the menu and then let the user select an item by number or name. If their selection

In python This time, we want to print the menu and then let the user select an item by number or name. If their selection is on the menu, we'll print a message letting them know we've put in their order; we'll keep asking them to select an option until they pick something on the menu. Requirements
how to write program to do the following:
1. Set a constant called MENU, with the value: ["ham", "eggs", "bacon", "fish", "toast", "spam", "fruit"]
2. Print a message welcoming the user to the caf.(Unlike assignment 2, you don't have to print the number of items on the menu, but you can if you like!)
3. Print a numbered list of items on the menu for the user. a. Remember to make the item list start at 1 and not 0!
4. Prompt the user to select an item from the menu by entering either the item number or the item name.
5. Check the user's selection to make sure they've picked an option on the menu. a. If entering by name, case must not matter: Eggs, eggs, and EgGs are all valid selections.
6. If the user's selection is not on the menu, print an error message, and then loop and re-prompt the user until they have made a valid selection.
7. Once the user has made a valid selection, print a message that includes the name of the food item and letting the user know an order is placed for them, then exit the program.
Sample Output
Welcome to the Breakfast Caf!
Please select a menu item:
1. ham
2. eggs
3. bacon
4. fish
5. toast
6. spam
7. fruit
Your order? salmon
Sorry, I don't think we carry that.
Please select a menu item: 1. ham 2. eggs 3. bacon 4. fish 5. toast 6. spam 7. fruit Your order? EgGs
A delicious order of eggs has been put in for you!

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 Programming Questions!