Implements, messily, a simple Tic-Tac-Toe AI.