This is a program I wrote circa 1979 as a University project (in Algol-W I think)
Click on a square to make a move when it's your turn