when can we use virtual destructor?
Answer Posted / yaggu
Basically, the characteristics it self defines, that
constructor can not be virtual but overloaded while in the
inverse to this, the destructor can not be
overloaded....means there may be more than one constructors
in class and when you create the object of the class,
constructor invokes and when you do not need at the same
time though you define more than one constructors but with
only one destructor we can destroy the object.....that is why...
Is This Answer Correct ? | 4 Yes | 4 No |
Post New Answer View All Answers
What is a hashmap c++?
How does code-bloating occur in c++?
What is split a string in c++?
What does asterisk mean in c++?
What is array in c++ pdf?
What is a set in c++?
What are the advantages of using pointers in a program?
What is the use of seekg in c++?
What do you mean by const correctness?
What is the limitation of cin while taking input for character array?
Why the usage of pointers in C++ is not recommended ?
What is a NULL Macro? What is the difference between a NULL Pointer and a NULL Macro?
What is scope resolution operator in c++ with example?
Write a program for Divide a number with 2 and Print the output ( NOTE: Check for divide by zero error).
what is data encapsulation in C++?