Skip to content

A simple Python-based coffee machine simulator that manages ingredient stock, processes user orders, and handles exceptions such as out-of-stock situations. Designed to demonstrate basic object-oriented programming, exception handling, and user interaction in a console application.

Notifications You must be signed in to change notification settings

shaikhf04/CoffeeMachineMiniProject

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

13 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Coffee Machine Mini Project β˜•

Coffee Bot

A terminal-based coffee machine simulator built in Python, designed to emulate a realistic coffee ordering experience. The system features ingredient stock management, interactive user input, and automated billing using the global keyword. Built with a modular, object-oriented structure, it also includes a custom logger that records user activity and system errors to a log file β€” making it both practical and production-aware.


πŸ“Œ Key Concepts Demonstrated

  • πŸ”Ή Object-Oriented Programming (OOP)
  • πŸ”Ή Custom Exception Handling
  • πŸ”Ή User Interaction via CLI
  • πŸ”Ή Custom Logger Writing to File
  • πŸ”Ή Use of global keyword for billing management
  • πŸ”Ή Clean and Modular Code Structure

πŸš€ Features

  • βœ… Validates ingredient availability before making coffee
  • ⚠️ Raises custom exceptions when ingredients are insufficient
  • πŸ“ Logs important events and errors to a log file via a custom logger
  • πŸ’¬ Provides a simple interactive menu for users
  • πŸ’° Uses the global keyword to manage and update billing across functions
  • πŸ”„ Easily extendable for new coffee options or features

πŸ› οΈ How to Run the Project

  1. βœ… Ensure Python 3.x is installed:

    python --version
    
  2. πŸ“₯ Clone this repository:

    git clone https://github.com/shaikhf04/CoffeeMachineMiniProject.git
    cd CoffeeMachineMiniProject
  3. ▢️ Run the app:

    python MakeCoffee.py
    

πŸ“ Project Structure

CoffeeMachineMiniProject/
β”œβ”€β”€ assets/              # Screenshots and image assets
β”œβ”€β”€ classes/             # Python class files (if modularized)
β”œβ”€β”€ logs/                # Log files generated by the custom logger
β”œβ”€β”€ main.py              # Main script to run the application
β”œβ”€β”€ README.md            # Project documentation
    ```

About

A simple Python-based coffee machine simulator that manages ingredient stock, processes user orders, and handles exceptions such as out-of-stock situations. Designed to demonstrate basic object-oriented programming, exception handling, and user interaction in a console application.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages