Game of Connect 4 with Alpha-Beta Pruning

Game of Connect 4 with Alpha-Beta Pruning

This project implements the classic game of Connect 4 using the Alpha-Beta pruning algorithm to optimize the decision-making process of the AI player. The game is played on a 7x6 grid where two players take turns dropping colored discs into a column, aiming to connect four of their discs in a row either horizontally, vertically, or diagonally.

Features

Example of board state:

   |   |   |   |   |   |
----------------------------
   |   |   |   |   |   |
----------------------------
   |   |   | R |   |   |
----------------------------
   |   | R | Y |   |   |
----------------------------
   | R | Y | Y | Y |   |
----------------------------
 R | Y | R | R | Y |   |
 
 R = Red player
 Y = Yellow player
 R wins

Getting Started

Main class: appli/Connect4Game.java