+ 1

I cannot run the exampleprogram.java created using notepad.

1st Feb 2017, 4:23 AM
DEEPAK KUMAR
7 Answers
+ 3
if u have installed the jdk u can compile it opening ur cmd, going to the directory that u saved ur file in and then execute command "javac filename.java" to compile it, to run it u just do "java filename"
1st Feb 2017, 4:42 AM
Kawaii
Kawaii - avatar
+ 2
cd Documents, press enter javac exampleprogram.java, press enter java exampleprogram, press enter
1st Feb 2017, 6:37 AM
Kawaii
Kawaii - avatar
+ 1
did u compile it?
1st Feb 2017, 4:25 AM
Kawaii
Kawaii - avatar
+ 1
i cannot compile nothing happens when i try to compile. How to compile?
1st Feb 2017, 4:27 AM
DEEPAK KUMAR
+ 1
i have saved it in c:\Users\HP\Documents\ExampleProgram.java but the cmd itself opens with c:\Users\HP> how to compile can u help
1st Feb 2017, 4:43 AM
DEEPAK KUMAR
0
when you open cmd.. type cd Documents and press enter.. and then compile the java program.. using javac ExampleProgram.java and finally use java ExampleProgram
1st Feb 2017, 5:13 AM
Ramu Bhusal
Ramu Bhusal - avatar
0
error occured says class names,'MyClass',are only accepted if annotation processing is explicitly requested
2nd Feb 2017, 6:08 AM
DEEPAK KUMAR