Object Oriented Programming With C Plus Plus - Multiple Choice Questions -013

121. ________ supports simultaneous input and output operations on file.
A. ifstream.
B. fopen.
C. ostream.
D. fstream.
ANSWER: D
122. ________ is a default access specifier for members of class in C++.
A. protected
B. public
C. private
D. default
ANSWER: C
123. A Class can have how many destructor?
A. 1
B. 2
C. 3
D. 4
ANSWER: A
124. The parameter list in function overloading must differ by?
A. Number of functions
B. Function Size
C. Function Name
D. Number of argument
ANSWER: D
125. Data members is also called?
A. Attribute
B. Method
C. Class
D. Object
ANSWER: A
126. In how many ways is polymorphism achived in C++?
A. 2
B. 1
C. 3
D. 4
ANSWER: C
127. A __________ is a special method used to initialize the instance variable of a class.
A. Member function
B. Destructor
C. Constructor
D. Structure
ANSWER: C
128. The ______ keyword brings the members of a namespace into view.
A. view.
B. using.
C. additive.
D. show.
ANSWER: B
129. If class A inherits from class B, then B is called _______ of A. A is called ________ of B.
A. Super class, Sub class
B. Subclass, Super class
C. Abstract class, Base Class
D. Child class, Sub Class
ANSWER: A
130. ________ is the mechanism which allows a class A to inherit properties of a class B.
A. Data abstraction
B. Encapsulation
C. Inheritance
D. Polymorphism

ANSWER: C

No comments:

Post a Comment