Q23: List out rules to define variables. Also define two different variables. OR Gives the example and write the rules for declaring identifier.

 

A23: Rules for define variables:

1.      It should begin with alphabet or underscore.

2.      Only alphabets, numbers, underscore can be used, no other special character or punctuation are allowed.

3.      It must not contain white space.

4.      It should not be a keyword and up to 31 character long.

 

e.g. (int primeNumber, float _avg).

Post a Comment

0 Comments
* Please Don't Spam Here. All the Comments are Reviewed by Admin.