Creating the Java Class



# Writing the First Program in Java

/* This is my First Program
To Display the message
Author:……….
Version:…….
Project:……….*/

import java.lang.*;
Class First{
// we initialize variables and methods here.
public static void main(String args[])
//The Java program is executed by JVM by calling the Main Method.
// The JVM starts execution of a java program from the main method().
{
System.out.println(”Hello World”);
System.out.println(”Welcome to Java”);
}
}

output:
Hello World.
Welcome to Java.

Random Posts

Post a Comment