This was a recent assignment in a class, that I wanted to properly document as part of today's challenges.

What it does

This program allows 2 players to engage in a game of tic tac toe.

How we built it

Program asks for Player names, then flips a coin to determine who goes first. Players are asked to input a number 1-9 to place a mark on the board, with boxes 1-3 on going from the top left to top right of the tic tac toe board, and etc. A board is plotted and the marks on the board are made using the BoardPlot function. A Checkwin function checks if there are 3 marks in a row after every turn. If a player wins, a win statement is displayed. If it ends in a tie, a tie statement is shown. After the conclusion of a round, the players are asked if they want to play again. If not, the program ends. This program was built completely in MatLab

Challenges we ran into

We ran into challenges when trying to get the code to stop when there were 3 marks in a row.

Accomplishments that we're proud of

Proud of learning Matlab and creating an interactive game!

What we learned

We learnt how to use MatLab!

Built With

Share this project: