Variables are used to store values temporary entered by a user. Variables are the entity that may vary during program execution. In order to use a variable we have to declare with its data type.
Syntax: data_type variable_name;
Rules to declare a variable:
1. A variable name can contain any sequence of letters, digits and underscore.
2. Special characters, blank space or any comma are not allowed.
3. The first character should be a letter, an underscore or @.
4. Upper and lower case letters are distinguishable.
5. A Keyword cannot be used to declare a variable name.