Skip to content

Implementation of the 8 Men Morris game using MiniMax and Alpha-Beta pruning algorithms, demonstrating AI strategies in game theory

License

Notifications You must be signed in to change notification settings

justine-george/morris-game-variant-project

Repository files navigation

8 Men Morris Game AI: MiniMax vs Alpha-Beta Pruning

This repository contains an implementation of the 8 Men Morris game, a variant of the classic board game, using both MiniMax and Alpha-Beta pruning algorithms. The project showcases different strategies and improvements for playing the game, demonstrating the effectiveness of these algorithms in game theory and artificial intelligence.

Explore the sample outputs to understand the AI's decision-making process and its effectiveness in different game stages.

Play the game

python3 playGame.py

Run the tests

python3 program_name.py input_board_file output_file max_depth

Sample plays

python3 MiniMaxOpening.py board1.txt board2.txt 2

MiniMaxOpening

python3 MiniMaxGame.py board3.txt board4.txt 2

MiniMaxGame

python3 ABOpening.py boardalphabeta1.txt boardalphabeta2.txt 2

ABOpening

python3 ABGame.py boardalphabeta3.txt boardalphabeta4.txt 2

ABGame

python3 MiniMaxOpeningBlack.py boardblack1.txt boardblack2.txt 2

MiniMaxOpeningBlack

python3 MiniMaxGameBlack.py boardblack3.txt boardblack4.txt 2

MiniMaxGameBlack

python3 MiniMaxOpeningImproved.py boardimproved1.txt boardimproved2.txt 2

MiniMaxOpeningImproved

python3 MiniMaxGameImproved.py boardimproved3.txt boardimproved4.txt 2

MiniMaxGameImproved

About

Implementation of the 8 Men Morris game using MiniMax and Alpha-Beta pruning algorithms, demonstrating AI strategies in game theory

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages