there could be many possible reasons for your failure. 1. Are you compiling it in the same directory or using the correct file path? 2. Is your file name correct? 3. Are you sure that you use the correct file extensions?and maybe other reasons. God knows!
用"javac e.java"编译
用"java e"运行如果还出现这种情况,设置一下CLASSPATH
[email protected]
1.将jdk1.4.0-安装在自己机器的某个盘符的根目录下,如:可安装在D:\下。
***(以下的d:\j2sdk1.4.0_01改为你自己安装JDK的目录)***
2.如果你的运行环境是win98,则在C盘根目录下,autoexec.bat文件中,加入下面两条语句:
set Path=%PATH%;d:\j2sdk1.4.0_01\bin
set CLASSPATH=.;d:\j2sdk1.4.0_01\lib\
(也可以写成:set CLASSPATH=.;d:\j2sdk1.4.0_01\lib\dt.jar;d:\j2sdk1.4.0_01\lib\tools.jar)
保存后,重新启动机器,就完成了jdk1.4的安装。
靠,拜托老兄看清点再说话!!没睡醒吧??!!
回复人: abigfrog(千年精灵)(★JAVA入门中★) ( ) 信誉:100 2003-4-18 11:28:45 得分:0
文件名必须和public class的类名完全一致,包括大小写。
1. Are you compiling it in the same directory or using the correct file path?
2. Is your file name correct?
3. Are you sure that you use the correct file extensions?and maybe other reasons. God knows!