I tried executing it in jdk1.4.1 and it is working successfully.
Since you have tried with the souce code given in CD the only viable option is
the class name and the file name doesn't match.
Just try checking the name you have given while saving the java file.
Java is case sensitive and I have come across this error when the
Java class file is created with some name other than the name of the
public class declared inside it.