Start tic-tac-toe game on the console.
objects that inherit
interval to take before an AI player to make decision, in second
At default, the game is played between humans.
ttt_ai() to play against
an AI player.
The strength of the AI can be adjusted by passing the
argument (0 (weekest) to 5 (strongest)) to the
To input your move, type the position like "a1". Only two-length string consisting of an alphabet and a digit is accepted. Type "exit" to finish the game.
You may set both
player2 as AI players.
In this case, the game transition is displayed on the console without
For conducting a large sized simulations of games between AIs, refer to
1 2 3 4
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.