How to write a coding in java

Go here and click "download jar file via http". Then open a terminal and go to the directory where the file drjava... has been downloaded. Then type

java -jar drjava*

In the window that opens, write

public class HelloWorld {
    public static void main(String[] args) { 
        System.out.println("Hello, World");
    }
}

Click Compile, save as HelloWorld.java. Click Run.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.