Example: class Hello { static void main (String [] args) { System.out.println ("Hello"); } } Now compile: javac Hello.java Compilation works But when you run: java Hello You get error: Main method not ...