To play is to move on the light brown to go to the treasure with the arrow keys, and when you go on the dark brown, you will hear a loud digging sound. Press the flag to play again!
I used a book called "CODE YOUR OWN GAMES!".