2080 7

CSC166 ยท 2080 ยท 5 marks

Describe the chain of constructors and destructors in inheritance.

Describe the chain of constructors and destructors in inheritance. [5]

Object Oriented ProgrammingChapter 5: InheritanceConstructor and Destructor in derived classes

In inheritance, when an object of a derived class is created or destroyed, constructors and destructors of both the base class and the derived class are automatically invoked in a specific order. --- When a derived class object is created, constructors are called in top-down order, i.e., from the...