Answer Posted / guest
Any class that may act as the base of another class should
have a virtual destructor. This ensures that when an object
of the derived class is destroyed that the derived class
dtor will be invoked to destroy it. If the destructor is not
virtual, under some common circumstances, only the base
class' destructor will be invoked, regardless of the class
actually being destroyed. For practical purposes this means
that a class which does, could or should have virtual member
functions, should also have a virtual destructor.
Is This Answer Correct ? | 18 Yes | 3 No |
Post New Answer View All Answers
What is object-oriented programming? Webopedia definition
What is the example of polymorphism?
What is the oops and benefits of oops programming?
What is multilevel inheritance explain with example?
What is oops concept with example?
Following are the class specifications: class {int a}; class {int b}; Using friend funtion,calculate the max of two objects and display it.
if i have same function with same number of argument but defined in different files. Now i am adding these two files in a third file and calling this function . which will get called and wht decide the precedence?
Who invented oop?
How do you define a class in oop?
Why is it so that we can have virtual constructors but we cannot have virtual destructors?
What is polymorphism and example?
Why do we use oops?
Is abstract thinking intelligence?
I have One image (means a group photo ) how to split the faces only from the image?............ please send the answer nagadurgaraju@gmail.com thanks in advace...
What are oops methods?