nicole peka wrote:I tried leaving the ".java" off (after compiling). An error occurred, I pasted it below.
Dave Tolls wrote:The 'java' command expects a fully qualified class name, and 'C:\Users\nicole\Documents\HelloWorld' is not a class name.
it needs to be:
java HelloWorld
All things are lawful, but not all things are profitable.
nicole peka wrote:Oops.. I will use code tags from now on. Yes I changed directory as well. I get the same error
______________________________________________
C:\Users\nicole>cd documents
C:\Users\nicole\Documents>javac C:\Users\nicole\Documents\HelloWorld.java
C:\Users\nicole\Documents>java HelloWorld
Error: Could not find or load main class HelloWorld
C:\Users\nicole\Documents>
All things are lawful, but not all things are profitable.
Consider Paul's rocket mass heater. |