Variable and Comment in C MCQs Exercise I
Ques 1
Variable and Comment
Which of the following is the property of Variable?
A We can change the value of variable
B It store value
C Both (a) and (b)
D None of these
Ques 2
Variable and Comment
Which one of the following is the correct option of variable declaration ?
A int A:
B int a;
C int $x;
D (a), (b) and (c)
Ques 3
Variable and Comment
Which keyword is used to make any variable as immutable variable in C Programming?
A int
B float
C const
D pointer
Ques 4
Variable and Comment
What is the purpose of a variable in C programming?
A To store comments
B To store data
C To perform mathematical operations
D To print output
Ques 5
Variable and Comment
Which of the following statements about comments in C++ is true?
A Comments are executed by the compiler.
B Comments are ignored by the compiler.
C Comments are necessary for the program to compile.
D Comments can only be used at the beginning of a program.