What is a pure virtual destructor in C++? What is its need, advantage and disadvantage, please explain with example?
When a function is declared as virtual and when a class ? Please explain with examples.