Contents

Which of the following access specifier are accessible inside the class and not accessible outside the class?
a) public specifier               
b) private specifier
c) protected specifier 
d) none of these

c

The special member function of class and it is used to initialize the class is called
a) constructor     
b) destructor
c) access specifier               
d) none of these

a

Which of the following are specific rules for naming of constructor?
a) same name as class
b) have no return type
c) both a & b                       
d) none of these

c

How many types of constructors in OOP?
a) one    
b) two    
c) three  
d) four

b

Explanation: default constructor, user define constructor


The constructor that accepts no parameters and reserves memory for an object is called….
a) user-define constructor                 
b) default constructor
c) default copy constructor              
d) none of these

b

The constructor that accepts parameter to initialize the data member of an object is called….
a) user-define constructor               
b) default constructor
c) default copy constructor                              
d) none of these

a