Contents

Which of the following is not a valid class specifier?
a) private                              
b) pointer
c) public                                
d) protected

b

What is the correct syntax for class?
a) class name{}; 
b) class name[];
c) class name();   
d) none of these

a

Which of the following class allows to declare only one object of it?
a) abstract class  
b) virtual class
c) singleton class
d) friend class

c

Which of the following are included in body of class?
a) data members
b) member function
c) both a & b                       
d) none of these

c

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

c

Explanation: private specifier, public specifier, protected specifier


Which of the following is the correct syntax of object?
a) object-name class-name;                             
b) class-name object-name;
c) class-name []; 
d) all of these

b