How do you know that your class needs a virtual destructor?
Answer Posted / nishikant sahu
If programmer intended to act the class as a BASE class
somewhere then it is rule of thumb or good programming that
you have to have declare your constructor virtual.
| Is This Answer Correct ? | 3 Yes | 6 No |
Post New Answer View All Answers
what is oops and list its features in c++?
What are the advantages of prototyping?
How many types of scopes are there in c++?
Where are setjmp and longjmp used in c++?
Why cout is used in c++?
What is the difference between cin.read() and cin.getline()?
How to get the current position of the file pointer?
Is dev c++ a good compiler?
Why do we learn c++?
Write about c++ storage classes?
what is data encapsulation in C++?
What is encapsulation in c++ with example?
Explain what are accessor methods?
explain the reference variable in c++?
What are pointer-to-members? Explain.