>

Triangle Puzzle in Java

This applet allow you to play the familiar Triangle Puzzle -- a puzzle that you see at the Friendly Restaurants. If you are unfamiliar with it, here is how you play.

The object of the game is to have only one peg left on the board. You eliminate pegs by jumping over them. You take away the peg over which you jumped. Eventually you have only one peg left or you have no other jumps that you can legally make.

In this applet you click on a peg with your mouse and drag it to a hole. After you lift the mouse button, the peg should move to the hole you picked and the peg you jumped should dissappear. This will happen only if you make a legal jump.

About the applet buttons:

Refresh will reset the game board so you can start again.
Solve will let you see how the computer solves the puzzle.
Window brings up the dialog window that tells you how you are progressing.
Quit on the window will dispose of the dialog window until you choose the Solve or Window button again.


Back To CS Main Page