In this section we will see how to comment your Java code.
We will also see the Identifiers and Keyword of Java API.
Properly commenting the Java code is very important. Commenting the programming code is one of the best practices of good programming. You should always comment your Java code properly.
Java provides three different methods of commenting the code.
Following table summarizes the different methods of commenting code.
a) Use // for commenting
b) Use /* .... */ for commenting
c) Use /** ..... */ for commenting in Java code
Java compiler ignores the text marked as comment.
The keywords are divided into three categories by expected student usage.
Variables - Local, Instance, ClassVariables may be local, instance (field), or static (class) variables. Formal parameters are local variables that are assigned values when the method is called.