Debugging. As you develop programs, you are almost certain to encounter errors, including incorrect results, nonterminating execution, or (rarely) machine crashes. When this happens, the Metrowerks debugger can be used to help locate problems. The debugger will be described in a later handout.
Macintosh Freezes. Occasionally, an error in a program will cause the Macintosh to hang --everything stops and the mouse and keyboard don't have any effect. In this case, first try to force the program to quit by typing Option-Command-Esc. If that works, save any open files and restart the machine to reinitialize the Mac.
If the forced quit doesn't work, the only solution is to restart the machine. On older Macs, the restart button is the leftmost of the two located on the left side of the front panel. If your Mac doesn't have a restart button, try holding down the Control and Command keys and then pressing the power-on button at the top of the keyboard. When you release these keys, the machine should restart.
Warning: Don't restart unless there is no other option. You will have to restart all applications that were running, and you will lose changes to documents that were modified but not saved.
Windows Freezes. While Windows doesn't lock up very often, we have seen situations where the Java environment starts behaving strangely, usually after some other problem has occurred. The best solution is to select Start|Shutdown... then select Restart the Computer to reinitialize Windows.