Hi everybody,
can you help me to solve this problem ?!!
I need your help please ..
(1) Define a structure named menuItemSpecificationType that stores ingredients in a menu item (string [4]) and a brief description of the item (string).
(2) Define a structure named menuItemType with four components: num (int), name (string), description (menuItemSpecificationType), and price (double).
(3) Define a structure named selectedItemType with two components: num(int) and quantity (int).
(4) Write a program to help a 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) Show the customer a description of a specific item according to the customer request.
(c) Allow the customer to select more than one item from the menu. The customer may ask for multiple items of one type.
(d) Calculate and print the bill.
Use an array, menuList, of struct menuItemType and an array choiceList of selectedItemType. Your program must contain at least the following functions:
(a) Function getData: This function loads the data into the array menuList. The number of menu items in the file is known. The prototype of the function is:
void getData(ifstream& inFile, menuItemType mList[], int listSize);
(b) Function showMenu: This function shows the different items offered by the restaurant and tells the user how to select the items. The function allows the user to select an item to display its description. The prototype of the function is:
void showMenu(menuItemType mList[], int listSize);
(c) Function makeSelection: This function allows the user to select menu items and specify their quantities. The prototype of the function is:
void makeSelection (menuItemType mList[], int listSize,
selectedItemType sList[], int& sListLength);
(d) Function printCheck: This function calculates and prints the check. Note that the billing amount should include a 5% tax). Format your output with three decimal places. The name of each item in the output should be left-justified.
The prototype of the function is: void printCheck(menuItemType mList[], int listSize, selectedItemType sList[], int sListLength);
Thanx in advance .. :)