Never use CLASSPATH. Use -classpath. If you set CLASSPATH, something might change it on you later. It's pointless to rely on that when it's trivial to supply the classpath with a switch. Furthermore, in most hello-world examples you are better off NOT setting CLASSPATH or -classpath. Then you learn that the current directory is the classpath by default.
How many more CLASSPATH questions? Oh, probably another 10,000,000 or so going forward.
posted 12 years ago
BTW, the information on that link is terrible. Too bad somebody doesn't update it with more and more accurate information in less space.
I can't take it! You are too smart for me! Here is the tiny ad: