A collection of classic, terminal-based games built entirely in Python. This repository serves as a showcase of foundational Python concepts, including Object-Oriented Programming (OOP), while-loops, user input handling, and standard library usage.
A fully playable terminal version of the casino classic. Play against the dealer (computer), place your bets, and try to get to 21 without busting!
- Features: Betting system, chip tracking, Ace adjustment logic, and dealer AI (hits until 17).
- Run:
python blackjack/blackjack.py
The classic 2-player board game. The board is mapped to the numpad for easy, intuitive play.
- Features: 2-player local pass-and-play, automatic win/tie checking, randomized first-player selection, and input validation.
- Run:
python tic_tac_toe/tic_tac_toe.py
An automated simulation of the card game War. Two virtual players are dealt half a deck each, and they play their top cards against each other until one player runs out.
- Features: Automated gameplay loop, complex "War" tie-breaker logic, and deck shuffling.
- Run:
python war/war.py
- Language: Python 3.x
- Libraries:
random(built-in) - Concepts Demonstrated: Classes & Objects, Dictionaries/Tuples, Error Handling (
try/except), Procedural Logic.
- Clone this repository to your local machine:
git clone [https://github.com/YourUsername/Python-Classic-Games.git](https://github.com/YourUsername/Python-Classic-Games.git)
Navigate into the project directory:
cd Python-Classic-GamesRun the game of your choice using Python 3:
python <game_name>.py