Page 1 of 1

About Question com.enthuware.ets.scjp.v6.2.67 :

Posted: Thu Feb 16, 2012 6:58 am
by ETS User
It will not execute because there is no . (dot) in default classpath.
I don't believe that is true.
$ unset CLASSPATH
$ java Foo
In Foo

Re: About Question com.enthuware.ets.scjp.v6.2.67 :

Posted: Thu Feb 16, 2012 8:25 pm
by admin
That is because you don't have a classpath, in which case Java assumes that default class path is ".".
The question says that the classpath is set to ./classes, in which case "." is not part of the classpath and so it will not look in the current directory.

HTH,
Paul.