When an object is created which function will be automatically invoked ?
Friend function
Destructor function
Static function
Constructor function
What is called default constructor ?
A constructor that accepts one parameter
A constructor that accepts two parameters
A constructor that accepts no parameter
A constructor that accepts three parameters
What is the return type of destructor ?
The class
Void
No return type
The same as the first data in the class
How many types of constructors are there in C++ ?
1
2
3
4
A class named Student must have a constructor whose name is :
Student
~Student
Constructor
None of the above
Which of the following are NOT provided by the compiler by default ?
Zero-argument constructor
Destructor
Dynamic constructor
Copy constructor
Which of the following statement is correct about constructor ?a) It has same name as that of the class to which it belongs.b) It does not have an return type.
A correct, B wrong
A wrong, B correct
Both A and B correct
Both A and B wrong
Which of the following statements are correct ?
Constructor is always called explicitly
Constructor is called either implicitly or explicitly, whereas destructor is always called implicitly
Destructor is always called explicitly
Constructor and destructor functions are not called at all as they are always inline
Which of the following statement is correct ?
A destructor has the same name as the class in which it is present
A destructor has a different name than the class in which it is present
A destructor always returns an integer
A destructor can be overloaded
Destructor has the same name as that of the class with a tilde symbol
Constructor has the same name as that of the class
Both a and b
Destructor has the same name as the first member function of the class