Skip to content

Latest commit

 

History

History
19 lines (15 loc) · 819 Bytes

README.md

File metadata and controls

19 lines (15 loc) · 819 Bytes

Beverages Machine

You have a beverages machine with 4 products: soda water, coca coal, orange juice and water. This machine accepts 4 kind of coins: 1$, 50 cents, 10 cents and 1 cent

todo:

  1. show input (i wrote unittests insted)
  2. user can add money (done)
  3. check if money is enought (done)
  4. N products and i'm out of one (done)
  5. return change (1$, 50 cents, 10 cents and 1 cent) (done)
  6. run out of money (specific coins? Done)
  7. machine states (done, but in very simple way. Source pattern is much more extensive)

todo #2:

  1. Show menu to user in console (no gui), with options to choose from and get product choice and money as input (check #1)
  2. What happens to machine state when transaction ends (it's switches to default state)
  3. Change to user (don't get it)