github.com/Zialus/TikTakToe

Min-Max(w/ and w/o Alpha-beta pruning) implementations for a CS Artificial Inteligence Class



Documentation

Tic-Tac-Toe-Swift

A swift implementation of Tic-Tac-Toe.

Swift Platform Travis

The decision making process for the computer moves is taken care by a straightforward MiniMax (with and without Alpha-Beta Pruning) implementation.

Instructions

How to compile the Tic-Tac-Toe program

To compile just use the provided Makefile by running the command:

make

on the terminal

How to run

./TicTacToe

For aditional debug functionality you can run the program with one of the following paremeters:

  • debug
  • fulldebug

For example:

./TicTacToe debug

How to "play"

The program will ask the player to pick his preferred symbol and will also let the player choose who plays first.

When the game gets going the player will be asked to input the row and column to place his symbol.

The coordinates are represented in the following format :

+++++++++++++++++++
| 0,0 | 0,1 | 0,2 |
+++++++++++++++++++
| 1,0 | 1,1 | 1,2 |
+++++++++++++++++++
| 2,0 | 2,1 | 2,2 |
+++++++++++++++++++