Question: Needs to be in c++ visual studio and uniqe code Write a program to help a local restaurant automate its breakfast billing system. The program
Needs to be in c++ visual studio and uniqe code
Write a program to help a local restaurant automate its breakfast billing system. The program should do the following: a. Show the customer the different breakfast items offered by the restaurant. b. Allow the customer to select more than one item from the menu. Each time an item is selected, its quantity ordered is increased c. Calculate and print the bill Assume that the restaurant offers the following breakfast items (the price of each item is shown to the right of the item): Plain Egg $1.45 Bacon and Egg $2.45 Muffin $0.98 French Toast $1.99 Fruit Basket $2.44 Cereal $0.69 Coffee $0.55 Tea $0.75 First, Define a struct, menuItemType, with three components: menuItem of type string, menuPrice of type double, menuOrdered of type integer. Then use an array, call it menuList, of the struct menuItemType. Your program must contain the following functions: Function getData: This function loads the data into the array menulist. Function showMenu: This function shows the different items offered by the restaurant and tells the user how to select the items. Function printCheck: This function calculates and prints the check. (Note that the billing amount should include a 5% tax)
- noncompiling (-50)
- Must have a struct and it MUST be of type menuItemType (members: menuItem, menuPrice, quantity) (if not named that way (except quantity), -5 for not following directions) - You variable of the struct can NOT have arrays within it (-5 if you do) - In main, must have an array of the struct variable (-5 if not) - Must have functions, at a minimum: getData, showMenu, and printCheck (-15 if no functions) can have more of course
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
