Hello world in eclipse Or How to create class file in eclipse
Right click on the source folder then select new, then click class then next popup will be show.
Type package name just like com.swain.cell.java.example.
Type class name just like Hello(Class name should be stating with capital letter).
Then finish.
// amazon ebay shopbob.com hotels.com canon newegg.com
Hello.java
packagecom.swain.cell.java.example;
public class Hello {
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
System.out.println("hello world");
}
}
Right click on the programme then popup will be show then select run as then java Application.
Output
Hello world
Comments
Post a Comment