Syntax of Import statement

Syntax of Import statement-:

Syntax
 
import java.packages_name.class_name.method();


Define Print() method-:


  • print() method is used to display message or result .
  • this method is available from "System class".
  • System class is available from "java.lang" packages.
Syntax of print()-:

import java .lang.System.out.print("msg");

  • import statement divided in to two parts 
  1.  import java.lang.*;
  2. System.out.print("msg");


0 comments:

Post a Comment

Enter Here Your Ideas and Comment to improve this Blog

Popular Posts

Nilesh Jha. Powered by Blogger.

Contact Form

Name

Email *

Message *

Copyright © Nilesh Jha's Blog |
|