YanivWein24 / Vendor_Coffee_Machine

This project simulates the functionality of a vendor coffee machine. this project was built twice, one time using functional programming and one time using Object-Oriented Programming.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Art

Requirements :

  • Python 3.0 or above.
  • Download the code or clone it to your local repository.
  • Choose version:
    • written in functional programming
    • written in Object Oriented Programming
  • Change admin_password - this password is used when refilling the machine
  • Run the machine on your chosen version using coffee_machine_functional.py or oop-coffee-machine/main.py

Features :

  • 4 Different types of coffee beverages
  • Resource control - check the machine's stock, and refill at any time! (refill is protected with administrator password)
  • If one or more ingredients is insufficient, the machine will abort from making coffee and ask the operator for a stock refill.
  • Money machine - calculates the received coins and checks if the amount is sufficient. returns change if necessary.
  • Support Quarters, Dimes, Nickles and Pennis as inputs.

Changing the admin_password :

In both versions you can find the variable "admin_password" in the beginning of the main() function:

def main():
    admin_password = "1234"

Change the default value "1234"to your preferred password.
Use this password whenever you need to refill the machine's stock

Screenshots :

Options:
Options

Order:
Order

Menu:
Menu

Report:
Report

Refill:
Refill

About

This project simulates the functionality of a vendor coffee machine. this project was built twice, one time using functional programming and one time using Object-Oriented Programming.


Languages

Language:Python 100.0%