For the game of Tic Tac Toe we will be storing the state of the game in a matrix M.
For this game:
We would store the state as this:
-1 1 1
1 -1 -1
1 -1 -1
If there were any blanks squares, they would be 0;
For this challenge, given a game state, does X (1) have a three in a row on any row, column or major diagonal?

Solution Stats

1779 Solutions

529 Solvers

Last Solution submitted on Jan 13, 2026

Last 200 Solutions

Problem Comments

Solution Comments

Show comments
Loading...

Problem Recent Solvers529

Suggested Problems

More from this Author51

Problem Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!