/** * @author Shengyang Zhong * @version 1.0 * @date 04.04.2002 * @package informatik2.hello * @class Hello2 */ // modular program: // - each class can get its own file; // - files can be compiled separately; // - class = module = compilation unit public class Hello2a { public static void main (String[] argv) { Mouth.say("Hello 2a, World!"); } // main } // Hello2a //--------------------- cut into two files ----------------------------- class Mouth { // public allows external use // static allows use without instantiation public static void say(String what) { System.out.println(what); } // say } // Mouth