Home / Engineering / Object Oriented Programming (OOP) MCQs / Page 1

Object Oriented Programming (OOP) MCQs | Page - 1

Dear candidates you will find MCQ questions of Object Oriented Programming (OOP) here. Learn these questions and prepare yourself for coming examinations and interviews. You can check the right answer of any question by clicking on any option or by clicking view answer button.

M

Mr. Dubey • 51.17K Points
Coach

Q. 1) Every class has at least one constructor function, even when none is declared.

(A) true
(B) false
(C) ---
(D) ---
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 2) Can constructors be overloaded?

(A) true
(B) false
(C) ---
(D) ---
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 3) What is the difference between struct and class in terms of Access Modifier?

(A) by default all the struct members are private while by default class members are public.
(B) by default all the struct members are protected while by default class members are private.
(C) by default all the struct members are public while by default class members are private.
(D) by default all the struct members are public while by default class members are protected.
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 4) An abstract class can be instantiated.

(A) true
(B) false
(C) ---
(D) ---
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 5) The default access level assigned to members of a class is              

(A) private
(B) public
(C) protected
(D) needs to be assigned
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 6) There is nothing like a virtual constructor of a class.

(A) true
(B) false
(C) ---
(D) ---
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 7) Which of the following operators allow defining the member functions of a class outside the class?

(A) ::
(B) ?
(C) :?
(D) %
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 8) Which type of class has only one unique value for all the objects of that same class?

(A) this
(B) friend
(C) static
(D) both a and b
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 9) Which one of the following is not a fundamental data type in C++?

(A) float
(B) string
(C) int
(D) char
View Answer Discuss Share

M

Mr. Dubey • 51.17K Points
Coach

Q. 10) What is a constructor?

(A) a class automatically called whenever a new object of this class is created.
(B) a class automatically called whenever a new object of this class is destroyed.
(C) a function automatically called whenever a new object of this class is created.
(D) a function automatically called whenever a new object of this class is destroyed.
View Answer Discuss Share