Complete C++ interview questions on destructors and virtual destructors

Destructor: If a base or derieved class does not have any members that are allocated on heap, would you still use a virtual destructor ? Why ? If base class or derived class object is not created dynamically then there is no need for virtual destructor…… still need virtual destructor Please tell us why we …

Complete C++ interview questions on destructors and virtual destructors Read More »