What does the 'volatile' keyword do in C++?
A. Indicates that a variable may be changed unexpectedly
B. Indicates that a variable cannot be changed
C. Declares a constant variable
D. Declares a global variable
Answer: Option A
A. Indicates that a variable may be changed unexpectedly
B. Indicates that a variable cannot be changed
C. Declares a constant variable
D. Declares a global variable
Answer: Option A
Which of the following is a valid variable name in C++?
A. myVariable
B. 123variable
C. variable&
D. float
What is the data type of the variable 'x' in the following declaration: double x = 3.14;?
A. int
B. double
C. float
D. char
Join The Discussion