Classnotes | JAVA01 | RecentChanges | Preferences Showing revision 1 The general structure for any computer program is to have some main function which is ran by default. This main function (or segment of code) is the basic one which, in turn, runs everything else. In many programming languages, this main function is, in fact, called main, and this is no different in Java.
Let's look at a rudimentary Java source:
class Hello {
public static void main(String[] arguments) {
// My first Java program goes here
}
}