0
How to compile java code?
3 Respostas
+ 2
os? if ur on linux um make sure u wrap ur main() method in a class lets say the name of the class is Doge. do these
javac filename.java
# that is to compile
java Doge
# this is to execute whatever is inside class Doge {}
done u gon see the output and stuff
if ur on windows idk
+ 1
hi,
in addition to the above answer,
u have to install jdk and set the environmental variable so that java can be used any where when u use cmd and check java - version to check java installed correctly