COMPUTER FUNDAMENTALS

COMPUTER SOFTWARE

PROGRAMMING LANGUAGES

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
No ____ is allowed in variable
A
+ sign
B
-sign
C
0
D
Blank space
Explanation: 

Detailed explanation-1: -Specifically, spaces are not permitted in the variable names, as the variable name must be a single word. The variable name may not start with a digit or underscore, and may not end with an underscore. Double underscores are not permitted in the variable names. Hence the correct answer is White space characters.

Detailed explanation-2: -White space is not permitted. This is forced from language designing. Compiler needs to find out the meaning of words. Compiler works on a “State Machine” method, and it needs to distinguish key words. Maybe placing variable names in “[” and “]” give us some solution(like SQL).

Detailed explanation-3: -Explanation: We can insert blank spaces between two words to improve the readability of the statement but no blank spaces are allowed within a variable, constant or keyword. The keywords cannot be used as variable names.

Detailed explanation-4: -Variable name may not start with a digit or underscore, and may not end with an underscore. Double underscores are not permitted in variable name.

There is 1 question to complete.