Jumping Square Applet

The applet on this page illustrates two ideas: It responds to the event that occurs when the user clicks the mouse somewhere in the applet. It runs a separate thread that continually displays the elapsed time and makes the square jump around even if the user doesn't generate any events at all.

Try to click on the jumping square. When you do, you score a "hit." If you click the mouse but don't hit the square, it counts as a "miss."

Back to the lab