
Make Your Program Both an Applet and an Application
Sometimes it’s convenient to have your program be runnable both as an applet and as an application. One simple way of accomplishing this derives from the fact that any class can have a main method. If you’ve written your program as an applet, just add a main method, in which