Files
basic-computer-games/89_Tic-Tac-Toe
Martin Thoma 1b1d50986b Python: Add type annotations to all 'print' functions (#662)
* Add test to superstartrek and fixes several issues in superstartrek - I probably introduced them 🙈
* Mastermind type annotations
2022-03-21 10:41:14 +01:00
..
2022-03-05 09:29:23 +01:00
2022-03-05 09:29:23 +01:00
2022-03-05 09:29:23 +01:00

Tic-Tac-Toe

The game of tic-tac-toe hardly needs any introduction. In this one, you play versus the computer. Moves are entered by number:

1   2   3

4   5   6

7   8   9

If you make any bad moves, the computer will win; if the computer makes a bad move, you can win; otherwise, the game ends in a tie.

A second version of the game is included which prints out the board after each move. This is ideally suited to a CRT terminal, particularly if you modify it to not print out a new board after each move, but rather use the cursor to make the move.

The first program was written by Tom Koos while a student researcher at the Oregon Museum of Science and Industry; it was extensively modified by Steve North of Creative Computing. The author of the second game is Curt Flick of Akron, Ohio.


As published in Basic Computer Games (1978):

Downloaded from Vintage Basic at http://www.vintage-basic.net/games.html

Porting Notes

(please note any difficulties or challenges in porting here)