SHARING KNOWLEDGE EACH OTHERS!

Saturday, December 27, 2008

Java - What are comments ?


In Java, comments are preceded by two slashes (//) in a line, or enclosed between /* and */ in one or multiple lines. When the compiler sees //, it ignores all text after // in the same line. When it sees /*, it scans for the next */ and ignores any text between /* and */. Let’s look why comments are important in a program. The compiler is not going to compile the statement after the line comment or between comments. So it will skip the statement then the rest will be compiled by the compiler. So you can give any description in comments.

GO TO CHAPTER 02

Stumble
Delicious
Technorati
Twitter
Facebook

0 Comments:

Post a Comment

Enter your email address:

 

SOFTWARES AND PLATFORMS Copyright © 2010 LKart Theme is Designed by Lasantha