Tic Tac Toe
Play against an AI that never makes a mistake — or pass the phone to a friend.
How to Play Tic Tac Toe
Click any empty cell to place your mark — X goes first, then O. The first player to get three marks in a row (horizontally, vertically or diagonally) wins. If all nine cells are filled with no winner, the game is a draw.
The AI uses the minimax algorithm, which means it plays perfectly — it will never lose. You can at best draw by playing correctly. Focus on the centre square first, then corners. In 2 Players mode, both players share the same device and take turns.
On Hard difficulty, the AI uses the minimax algorithm with alpha-beta pruning — it evaluates every possible future board state and always picks the optimal move. Against a perfect minimax player, the best result a human can achieve is a draw. It is mathematically impossible to win.
Medium difficulty uses minimax to depth 3, so it plays well but makes occasional suboptimal choices. Easy picks random valid moves, making it a fair challenge for beginners.