Question: JAVA Problem specification You are required to implement a vending machine. This machine accepts 50,25,10,5 coins. Customer enters the money and the code of the

JAVA
 JAVA Problem specification You are required to implement a vending machine.

Problem specification You are required to implement a vending machine. This machine accepts 50,25,10,5 coins. Customer enters the money and the code of the product to purchase. You are required to give the change back. The goods' prices and products code are in file price.txt. You need to show the customer the price of each good. (If the money for purchasing the products is not enough, you need to report an error.) Format of the file (price.txt) is as follow: Code description price e.g. 1 Coke 100 2 K Kat 75 You are I quired to show the user all the products available plus its code and price. Method User enters the money as much as s/ he wants. Then enters the product's code. The product is then delivered. Hints All the products' prices are a multiple of 5

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!