Question: INPUT FILE FOR PROJECT Sinclair Community College 0.50 6 0.75 5 0.50 9 0.75 4 1.00 3 Wright State University 0.90 4 1.00 6 0.90



INPUT FILE FOR PROJECT
Sinclair Community College 0.50 6 0.75 5 0.50 9 0.75 4 1.00 3 Wright State University 0.90 4 1.00 6 0.90 3 1.00 2 1.25 4 University of Dayton 1.00 3 1.25 5 1.00 2 1.25 6 2.00 4 The Ohio State University 0.80 5 0.90 4 0.80 7 0905 3 1.50 2 Clark State Community College 0.75 1 0.85 2 0.75 4 0.85 2 1.00 5 Ohio University 1.00 2 1.25 6 1.00 7 1.25 3 1.50 2
Write a menu-driven program to keep track of the inventory and sales for a vending machine company's machines at various college campuses. Input File vendingMachines.xt Contains the data for each of the machines. The data on each machine consists of 6 lines of input. The first line contains the location (college), 5 additional lines contain a number representing the number of bottles in the machine for each of the brands -Coke, Diet Coke, Sprite, Sprite Zero and Dasani Requirements . Use the following Structure enum SodaBrands (COKE, DIET_COKE, SPRITE, SPRITE_ZERO, DASANI struct Drinks double price; int numSodas const int MAX SODA BRANDS: 5 struct vendingMachine string location; Drinks sodasIMAX SODABRANDS]; . Define an array of vendingMachine structs to store the data from the input file. Assume that there are no more than 10 vendingMachines. NOTE that each struct contains an array of Drinks structs indexed by the enumerated type SodaBrands. . Main Program . Read the input file into the array of structs . Use a while loop, calling functions to display the menu of locations and input the user's location choice, and process the user's selection. . At the end of the program display the contents of the array to show that the inventory has been updated based on the sales . Suggested Functions
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
