/connect-four-game

Connect Four Game AI Implementation with Javascript, Using Minimax Algorithm and Alpha-Beta Pruning

Primary LanguageJavaScript

Connect Four AI Implementation

This project was done as part of the CSE4082 - Introduction to Artificial Intelligence Course at Marmara University (Instructor: Ali Haydar Özer).

About the Project

You can find the details of the project under Project Files folder.

Usage

This is a Connect Four game AI implementation using minimax algorithm and three different evaluation heuristics to be used in minimax. You can play human vs human, human vs AI and AI vs AI. You can adjust the number of plies of the AI players (depth of minimax) and the evaluation heuristic they use.

It has a 7x8 game board unlike the standard Connect Four game, but you can just change the initialBoard array at index.js to have the board with the dimensions you need.

To Run The Code

git clone https://github.com/barishazar3431/connect-four-game.git

cd connect-four-game

npm install

node src/index.js