Cubic tic-tac-toe: A matching-based approach

John W. Cain, Ioannis M. Raymond, Nora C. Källersjö

Published: 2025/9/25

Abstract

In the natural generalization of tic-tac-toe to an $n \times n \times n$ board where $n \in \mathbb{N}$, it is known that the first player has a winning strategy if $n \leq 4$ and that either player can force a draw if $n \geq 8$. The question of whether the first player has a winning strategy if $n = 5, 6$ or $7$ has remained open. Here, we prove that the first player does not have a winning strategy if $n = 7$. The proof, which is computer-assisted, exploits the fact that the second player's first four moves can always be chosen such that their remaining moves can be automated via a simple pairing strategy. The process of finding the pairing strategy involves reframing the problem in such a way that the goal is to seek a maximal matching in a bipartite graph that represents the tic-tac-toe board after each player has made four moves. We use the Hopcroft-Karp matching algorithm to find such maximal matchings.

Cubic tic-tac-toe: A matching-based approach | SummarXiv | SummarXiv