This repository contains several small games implemented in different programming languages. Each game is stored in its own directory. Below is a brief description of each game and instructions on how to run them.
A simple implementation of the BlackJack card game.
Files:
art.pymain.py
How to run:
python main.pyA number guessing game where the player tries to guess a randomly generated number.
Files:
Guess_the_number.c
How to compile and run:
gcc Guess_the_number.c -o Guess_the_number
./Guess_the_numberA game where players take turns removing matchsticks. There are fair and unfair versions.
Files:
Matchstick_game.cMatchstick_game_unfair.c
How to compile and run:
# Fair version
gcc Matchstick_game.c -o Matchstick_game
./Matchstick_game
# Unfair version
gcc Matchstick_game_unfair.c -o Matchstick_game_unfair
./Matchstick_game_unfairA classic ping pong game with paddle and ball. The speed of the paddle increases each time the player hits the ball, adding an extra layer of challenge and excitement.
Files:
ball.pymain.pypaddle.pyscoreboard.py
How to run:
python main.pyThe classic snake game where the player controls a snake to eat food and grow.
Files:
food.pymain.pyscoreboard.pysnake.py
How to run:
python main.pyA command-line version of the classic stone-paper-scissor game with fair and unfair versions.
Files:
Stone_paper_scissor.cStone_paper_scissor_unfair.c
How to compile and run:
# Fair version
gcc Stone_paper_scissor.c -o Stone_paper_scissor
./Stone_paper_scissor
# Unfair version
gcc Stone_paper_scissor_unfair.c -o Stone_paper_scissor_unfair
./Stone_paper_scissor_unfairA game where the player controls a turtle to cross a road filled with moving cars.
Files:
cars.pymain.pyplayer.pyscoreboard.py
How to run:
python main.pyA game to identify US states on a map.
Files:
50_states.csvblank_states_img.gifmain.py
How to run:
python main.pyFeel free to fork this repository, make improvements, and create pull requests. All contributions are welcome!