Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Write a program to help a local resturant automate its breakfast billing system

ID: 3555134 • Letter: W

Question

Write a program to help a local resturant automate its breakfast billing system . Write a program to help a local resturant automate its breakfast billing system. the program should do the following : the program should do the following:
a. a. Show the customer the different breakfast items offered by the resturant. Show the customer the different breakfast items offered by the resturant.
b. b. Allow the costimer to select more than one item from the menu . Allow the costimer to select more than one item from the menu.
c. c. Calculate and print the bill . Calculate and print the bill.
Assume that the resturant offers the following breakfast items ( the price of each item is shown to the right of the item): Assume that the resturant 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 Bacon and Egg 2.45
muffin 0.99 muffin 0.99
French Toast 1.99 French Toast 1.99
Fruit basket 2.49 Fruit basket 2.49
Cereal 0.69 Cereal 0.69
Coffee 0.50 Coffee 0.50
Tea 0.75 Tea 0.75

use an array , menuList, of the struct menuItemType. use an array, menuList, of the struct menuItemType.
your program must contain at least the following functipons : your program must contain at least the following functipons:
* function getData: this function loads the data into the array menuList. * 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 sellect the items. * Function showMenu: this function shows the different items offered by the restaurant and tells the user how to sellect the items.
* function printCheck : this function calculates and prints the check. * Function printCheck: this function calculates and prints the check.
(note that the billing amount should include the 5% tax) (Note that the billing amount should include the 5% tax)

format your output with two decimle places. format your output with two decimle places. the name of each item in the output must be left-justified. the name of each item in the output must be left-justified. Customer should be able to select multiple items of a particular type.

Sample Output in this Case is:

Welcome to Johnny's Resturant

1 Bacon and Egg 2.45

2 muffin 1.98

1 coffee .50

   tax .25

Amount Due 5.18

Explanation / Answer

#include <iostream>
#include <fstream>
#include <cstdlib>
using namespace std;
double showmenu()
{
int choice=0,quantity;
double subtotal=0;
cout << "Welconme to Johnny's Resturant!" << endl;
cout << "May I take your order" << endl;

cout << "1. Plain Egg 1.45" << endl;
cout << "2. Bacon and Egg 2.45" << endl;
cout << "3. muffin 0.99" << endl;
cout << "4. French Toast 1.99" << endl;
cout << "5. Fruit basket 2.49" << endl;
cout << "6. Cereal 0.69" << endl;
cout << "7. Coffee 0.50" << endl;
cout << "8. Tea 0.75" << endl;
while(choice!=10)
{
cout << " Enter Selection (10 to print check): ";
cin >> choice;

if(choice!=10)
{
cout << "Quantity: ";
cin >> quantity;

if(choice==1)
{
subtotal=subtotal+(quantity*1.45);
}
if(choice==2)
{
subtotal=subtotal+(quantity*2.45);

}
if(choice==3)
{
subtotal=subtotal+(quantity*0.99);
}
if(choice==4)
{
subtotal=subtotal+(quantity*1.99);
}
if(choice==5)
{
subtotal=subtotal+(quantity*2.49);
}
if(choice==6)
{
subtotal=subtotal+(quantity*0.69);
}
if(choice==7)
{
subtotal=subtotal+(quantity*0.5);
}
if(choice==8)
{
subtotal=subtotal+(quantity*0.75);
}
}
}
return subtotal;
}

void printcheck(double subtotal)
{
double total,tax;
tax=subtotal*0.05;
total=subtotal+tax;
cout<<" tax "<<tax;
cout<<" Amount Due "<<total;
}

int main()
{
double subtotal=showmenu();
printcheck(subtotal);
return 0;
}

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote