Introduction

Java is a pure object oriented platform Independent programming language; specially designed for use in the distributed environment of the Internet.It is derived from the C-syntaxes and C++ Object-oriented features.But yet, it is simpler to use than C++.

 


A valid Java identifier allowed following characters only:

  • a - z

  • A - Z

  • 0 - 9

  • $ (Dollar Symbol)

  • _ (Underscore)

Rules

  1.  

    Can't start with a digit

  2. Java identifiers are case sensitive, of course the language Java itself is treated as case-sensitive programming language.

  3. There is no any length limit for java identifiers but it is not recommended to take too lengthy identifiers.

  4. We can't use Reserved Words as Identifier.

  5. All pre-defined (built-in) java class names & interface names, we can use as identifiers. Even though it is valid, But it is not a good programming practice, because it reduces readability and creates confusion.