Question: Please help with coding for this Project: Vending Machine Write a C- menu driven program to simulate a vending machine using functions. The vending 217
Project: Vending Machine Write a C- menu driven program to simulate a vending machine using functions. The vending 217 machine has the following items Item name Coke Doritos Smckers Chex Mix Pepsi Item price 0.55 $0.60 $0.90 Maximum capacity for each item is 30 If the number of items for each of the above is less than 5, then refill it. The machine accepts quarters, dimes, and nickels, and $1 or $5 bills. There are three different containers for each coin. There shoukd be at least 20 nickels, 20 dimes, and 20 quarters in each container. If each container has more than 100 coins, then remove coins from container and leave only 20 coins. If amount of $1 bils exceeds $100, then remove the $1 bills and leave twenty $1 bills in the container. If amount of S5 bills exceed 8300, then remove $5 bills and leave twenty $5 bills in the container The cost of the items is 35% of the selling price. Labor cost is 2S% of the selling price. Overhead is 5% of the selling price. Your program must run for six hours per day. Your program must have at least the following functions 1. Main function 2. Menu function 3. Check if the machine is ON or Off 4?Turn the machine ON if it is OFF 5. Refill vending machine 6. Refill coins containers 7. Remove colns from any one of the container if it exceeds 100 coins 8. Select item from vending machine 9. Accept coins 10. Check for coin validity. If it is a foreign coin, then reject it 11. Check the price. If the amount received is less than the item's price, then ask for more money. If the amount received is more than the item's price, then return change 12. Return change 13. Calculate the sales for each item per hour
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
