Identifiers can be defined as the name of the variables and some other program elements using the combination of the following characters.
Alphabets : A to Z, a to z
Numbers : 0 to 9
Underscore : _
Some other : like ,blank space,( ),*, & etc.
In C++ upper case and lower case letters are distinct and hence there are 52 letters in all.C++ does not set a maximum length for identifier.Some example of valid identifiers are as follows:
My_name , a , A, k_ Love etc.
In above examples the a and A identifiers are distinct and the underscore character is counted as a letters.Some invalid identifiers are :
3sd -variable begin with a digits
roll no – space between characters of a single variable
Operator in C++
operator are mathematical symbols,which are used to perform some logical and mathematical calculation.operators are three ...read more
Variable in C++
Variable are used to hold the value.We can change the value of a variable depending ...read more
Keywords in C++
The keywords are identifiers but cannot be user defined, since they are reserved words. So, ...read more
Constant in C++
Constant are also known as Literals.They are fixed. We cannot change them. for example a=10; a is ...read more