.

Friday 27 March 2015

"Hello World" program in JAVA

Steps to develop a hello world program in java-


class Hello {
//Everything should be written inside this block
public static void main(String args[])
{

//to print on the console
 System.out.println("hellow world");

}
}

1. Everything in the world is defined in terms of class.If you want to go for developing car first you will design the model for it. In Every car everything will be same as the model but objects can hold different characterstics(objects are real world entities in case of car it can be Honda city, Tata nano, swift desire)

Class- class is nothing but a blueprint of an object.

System.out.println("") is a method to print anything inside the parameter on the console.where System is a class, out is its object and println() is a method of it.






No comments:

Post a Comment