C++ Programming - Constructors and Destructors - Discussion

Discussion Forum : Constructors and Destructors - General Questions (Q.No. 17)
17.
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.
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
13 comments Page 2 of 2.

Naveen said:   7 years ago
Can you explain why destructor cannot be overloaded?

Vilady said:   6 years ago
The constructor has the same name as the class, and the destructor's name isnt the same as the constructors, which means the destructor's name is not the same as the class' name.
(1)

Surekha said:   4 years ago
Please explain about option C.


Post your comments here:

Your comments will be displayed after verification.