Programming - C++ Language

You Are Here :: Home > C++ Language > constructor - General Questions

 
37.

Which of the following statement is correct about destructors?                        


A. A destructor has void return type. B. A destructor has integer return type.
C. A destructor has no return type. D. A destructors return type is always same as that of main().




38.

Which of the following implicitly creates a default constructor when the programmer does not explicitly define at least one constructor for a class?                        


A. Preprocessor B. Linker
C. Loader D. Compiler




39.

Destructor calls are made in which order of the corresponding constructor calls?                        


A. Reverse order B. Forward order
C. Depends on how the object is constructed D. Depends on how many objects are constructed




40.

A constructor that accepts __________ parameters is called the default constructor.                        


A. one B. two
C. no D. three




41.

What happens when a class with parameterized constructors and having no default constructor is used in a program and we create an object that needs a zero-argument constructor?                        


A. Compile-time error. B. Preprocessing error.
C. Runtime error. D. Runtime exception.




42.

Which of the following never requires any arguments?                        


A. Member function B. Friend function
C. Default constructor D. const function




« prev

1

2

3

4

5

6

7

8

9

next »

 
 



© 2013 freshersindia.in ® | Copyrights | Terms & Conditions
   Designed by Freshers India
Catch Us on