Java's Legal Identifiers Naming Rules
The Java Legal Identifiers may comprise of following things :
1. Unicode Characters
2. Currency Symbols
3. Connecting Characters (Like Underscores "_")
For SCJP Exam you must know following few rules for having Legal Identifiers such as :
1. Identifiers must start with a letter , a currency symbol (such as $) , or an connecting character (such as _ ) but remember it should not start with a number (strictly prohibited).
2. After placing of the first character Identifiers may contain above three characters including Numbers.
3. As such Java doesn't place any limit to the number of characters an identifier may contain.
4. Generally Java Programmers should not use Java Keywords .... they are been used for program to code special meaning.
5. Java is a Case-Sensitive language remember you cannot place Tot in place of tot or toT etc ... They all are different stand alone Identifiers.
For more of such posts visit my new website
For more of such posts visit my new website
0 comments:
Post a Comment