Determine which of the following are valid identifiers? If invalid explain why?

[TU,BSCCSIT,2066]

a. record1 => Valid
b. 1record => Invalid Identifier name must start with alphabets
c. file_3 => Valid
d. return => Invalid Keywords cannot be used as identifiers
e. #tax => Invalid Identifier should not contain any special symbols except underscore (_) symbol.
f. name => Valid
g. goto =>  Invalid It is a keyword and cannot be used as identifier.
h. name and address =>  Invalid No white spaces are permitted in name of identifier.
i. name-and-address =>  Invalid Identifier should not contain any special symbols except underscore (_) symbol.
j. 123-45-6789  =>  Invalid Identifier should not contain any special symbols except underscore (_) symbol. And also identifier name must start with alphabet.
k. void =>  Invalid It is a keyword and cannot be used as identifier.
l. name_address => Valid

0 comments:

Feel free to contact the admin for any suggestions and help.