When a derived class object is deleted which gets deleted first - the base class object or the derived class object? |
Answer
When there is no further use of derived class obect in execution sequence then It gets deleted.
calling of distructor sequence is reverse of constructor calling sequence ,so first derived class obect deleted than base class obect.
|
|
|
First answer by K79mahesh. Last edit by K79mahesh. Contributor trust: 63 [recommend contributor]. Question popularity: 83 [recommend question]
|
Research your answer: |
Can you answer other questions about programming?
|
|


