Try this...
compile with this command
javac [javafilename].java
then after u get the classfile (the bytecode)
run using :
java -classpath . [javafilename]
this will specify that the classpath is the current directory ( . ----> refers current working directory).