C++ Identifiers.

C++ Programming Tutorial

C++ Identifiers.


The name that we give to an entity in the program so that it can be uniquely identified, is called "identifier". The names of variables, functions, labels of a class, and other user-defined objects are called 'identifiers'. ‘Identifiers’ cannot be used as keywords.






List of identifiers.

  1. Constants.

  2. Variables

  3. Functions

  4. Labels

  5. Defined data types


Rules for identifiers declaraion.

  1. Only alphabetic characters, digits, and underscores are allowed.

  2. The identifier name cannot start with a digit.

  3. Therefore, we can say that C++ identifiers are case-sensitive. For eg int 'a' and int 'A' are differnt variables.

  4. A declared keyword cannot be used as a variable name.