The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | Jul 2017 |
| Last Sign in: | 314 Weeks Ago |
| Questions Answered: | 15833 |
| Tutorials Posted: | 15827 |
MBA,PHD, Juris Doctor
Strayer,Devery,Harvard University
Mar-1995 - Mar-2002
Manager Planning
WalMart
Mar-2001 - Feb-2009
Please help! Python 3 no java =)
Write a menu-driven program that allows a user to create a shopping list. Â
The user should have the option to add an item, remove an item, sort and print the list and quit the program.
If the user attempts to remove an item that is not on the list, the program should not crash (i.e., you should check if the item is in the list before attempting to remove it). Â
If the user chooses to print the list, the printed list should be numbered.
The program should keep displaying the menu until the user decides to quit. Â
Do user validation to make sure the user enters a valid choice from the menu.
The program should continue asking the user until the user quits.
Here is an example of what your program’s menu should resemble:
a - Add an Item
r - Remove an Item
s - Sort Shopping List
p - Print Shopping List
q - Quit
Please enter your choice:
Here is an example of what your shopping list should look like when printed:
Your Shopping List contains:
1. waterÂ
2. bread
3. pills
4. oil
Here is an example of what your shopping list should look like when printed after sorted:
Your Shopping List contains:
1. bread
2. oil
3. pills
4. water
----------- Â ----------- H-----------ell-----------o S-----------ir/-----------Mad-----------am ----------- Th-----------ank----------- yo-----------u f-----------or -----------you-----------r i-----------nte-----------res-----------t a-----------nd -----------buy-----------ing----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n. -----------Ple-----------ase----------- pi-----------ng -----------me -----------on -----------cha-----------t I----------- am----------- on-----------lin-----------e o-----------r i-----------nbo-----------x m-----------e a----------- me-----------ssa-----------ge -----------I w-----------ill----------- be----------- qu-----------ick-----------ly