Java Compile-Time Errors


javac: Command not found Installation problem or environment problem: The PATH is not set properly
WelcomeToJava.java:3 Method
printn(java.lang.String) not found in class
java.io.PrintStream.

    System.out.printn ("Welcome To Java !");
                     ^

The method println is misspelled.

Java Run-Time Errors


Can't find class Welcometojava The error is generated when typing

java Welcometojava

Generally this means that the class name was spelled differently from the source file name.

Back To Java School