Contents

What does the derive class inherit from the base class?
a) public and protected members  
b) public and private members
c) only public members     
d) everything

a

Which of the following member of base class are never accessible to derive class?
a) public members              
b) private
c) protected                          
d) all of these

b

What is the name of derive class in following statement?
class car: protected vehicle                               
a) car                                    
b) vehicle
c) protected                          
d) all of these

a

Which of the following class declaration indicates that ball is derive class of sphere?
a) class sphere: public ball                
b) class ball: public sphere
c) class ball :: sphere
d) class ball(sphere)

b

A subclass inherits all of the following members of its superclass except?
a) constructor and destructor
b) public methods
c) data fields                        
d) protected methods

a

A base class may have at most …… child classes derived from it.
a) 1                        
b) 2                        
c) 12                      
d) many

d