I finally picked up my JAVA books again to get into the subject this year, but so far it's been more struggle than fun. I started with the easiest code listing one could imagine.
It compiles fine (using "javac" in Terminal), but I can neither run the compiled class file in Finder nor via Terminal.
Even the examples from other websites (O'Reilly etc.) won't show any sign of life, although at least they give me an error message (Jar Launcher: The jar file "YaddaYadda.class" couldn't be launched. Chek the Console for possible error messages). Which isn't much of help at this point.
What could be wrong?
Code:
public class Hello
{
public static void main (String[] args)
{
System.out.println("Hello World!");
}
}
It compiles fine (using "javac" in Terminal), but I can neither run the compiled class file in Finder nor via Terminal.
Even the examples from other websites (O'Reilly etc.) won't show any sign of life, although at least they give me an error message (Jar Launcher: The jar file "YaddaYadda.class" couldn't be launched. Chek the Console for possible error messages). Which isn't much of help at this point.
What could be wrong?