Question: In JAVA Please A vending machine as a dynamic number of items, each with their own cost and quantity. As an item is sold, the
In JAVA Please
A vending machine as a dynamic number of items, each with their own cost and quantity. As an item is sold, the quantity goes down.
A vending machine has a fixed amount of money to make change, say $500. If a person pays the exact amount, the amount available to make change increases, otherwise, the total sales for the day goes up and the money available for change needs to be updated.
Use arrays for inventory/amount/quantity (multi dimension array) and the quantity of change on hand.
Be sure to use functions
Write pseudocode!
Write code (and test your code)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
