The program builds a 10x10 board, randomly picking 10 coordinates on which 'ships' are located. The user guesses ship locations by clicking on the board, placing white pegs for a 'miss', and red pegs for a 'hit'.
As soon as the user hits the last 'ship' the program writes a winning message including the number of guesses it took and exits.