day 16

from menu import Menu, MenuItem

from coffee_maker import CoffeeMaker

from money_machine import MoneyMachine


money_machine = MoneyMachine()

coffee_maker = CoffeeMaker()


coffee_maker.report()

money_machine.report()

is_on = True

menu = Menu()



while is_on:

options = menu.get_items()

choice = input(f"What would you like? ({options})")

if choice == "off":

is_on = False


elif choice == "report":

coffee_maker.report()

money_machine.report()

else:

drink = menu.find_drink(choice)

check = coffee_maker.is_resource_sufficient((drink))

if check:

if money_machine.make_payment(drink.cost):

coffee_maker.make_coffee(drink)