Java Introduction

Java programming language are very easy to learn .

The main Method

the main method must be identical to this signature:
public static void main(String[ ] args)
public: anyone can access it
- static: method can be run without creating an instance of the class containing the main method
- void: method doesn't return any value
- main: the name of the method


   System.out.println("Hello World!");

The println method prints a line of text to the screen. The System class and its out stream are used to access the println method.

Semicolons in Java

class MyClass {
  public static void main(String[ ] args) {
    System.out.println("I am learning Java");
each code statement must end with a semicolon.