Detecting Victoryλ︎
So far we can play the game until all the cells contain either a nought or cross.
Lets add some code to detect winning moves.
A winning move is one of either
- a row of 3 consecutive noughts or crosses
- a column of 3 consecutive noughts or crosses
- a diagonal line of 3 consecutive noughts or crosses