11. One of the methods to stop the execution of the function
is by calling the standard ________ function.
A. goto.
B. jump.
C. stop.
D. exit.
ANSWER: D
12. What is a Constructor?
A. A function called when an instance of a class is
initialized.
B. A function that is called when an instance of a class is
deleted.
C. A special function to change the value of dynamically
allocated memory.
D. A function that is called in order to change the value
ANSWER: A
13. _________ is a relationship between classes.
A. Polymorphism.
B. Inheritance.
C. Overloading.
D. Overriding.
ANSWER: B
14. A ________ function is a function that has no body
inside its base class.
A. inline.
B. friend.
C. constructor.
D. pure virtual.
ANSWER: D
15. A continue statement causes execution to skip to ____.
A. the first statement after the loop.
B. the statement following the continue statement.
C. the return 0; statement.
D. the next iteration of the loop.
ANSWER: D
16. In a group of nested loops, which loop is executed the
most number of times?
A. The outermost loop.
B. The innermost loop.
C. All loops are executed the same number of times.
D. Cannot be determined without knowing the size of the
loops bottom of form.
ANSWER: B
17. A ________ converts from an object of the type of the
constructor's parameter to an object of the class.
A. conversion function.
B. member function.
C. class conversion.
D. conversion constructors.
ANSWER: D
18. In C++, 14 % 4 = ____.
A. 1.
B. 2
C. 3
D. 4
ANSWER: B
19. Variables that are declared, but not initialized,
contain ________.
A. blank spaces.
B. zeros.
C. "garbage" values.
D. nothing - they are empty.
ANSWER: C
20. Array indexing always starts with ______.
A. 0
B. 1
C. 2
D. \0
ANSWER: A
No comments:
Post a Comment