The ttt command starts the tic-tac-toe game. This is a learning version but it learns slowly. It loses nearly 80 games before completely mastering the game. When you start the game you are prompted Accumulated knowledge? (Yes or No). Entering y provides the computer with knowledge gained from previous games.
You are always X and your opponent is always O. You can either make the first move or pass to your opponent. To pass, press the enter key when prompted Your move? at the beginning of the game. The first to get three in a row wins the game. For example:
new game 123 456 789 Your move? 1 XO3 456 789 Your move? 9 XOO 456 78X Your move? 5 You win
In the example, your first move was to place an X where 1 was located. The computer placed an O where the 2 was located. The game progressed until you had three in a diagonal row (1,5, 9). The game repeats until you quit. To quit the game, press the Interrupt (Ctrl-C) or End Of File (Ctrl-D) key sequence.
-e | Increases the speed of the learning. |
-i | Displays the instructions prior to the start of the game. |
$HOME/ttt.a | Specifies the location of the learning file. |
/usr/games | Specifies the location of the system's games. |
The arithmetic command, back command, bj command, craps command, fish command, fortune command, hangman command, moo command, number command, quiz command, turnoff command, turnon command, wump command.