< Prev
Next >

Hybrid Inheritance in C++

In our previous article, we introduced you to one of the types of inheritance - hierarchicalinheritance. Today we are going to discuss the another type of inheritance in C++ named - hybrid inheritance. Hybrid inhertance is performed when we have to mix different types of inheritance within a single program, for example, mixing single inheritance with multiple inheritance or multiple inhertance within a single program.

The class at the topmost-level is known as base class and the classes that inherit the features of the class at the topmost-level is called subclasses or derived classes,

What features a subclass inherits from its base class, through inheritance?

Note - Base class members marked with private visibility mode are never inherited.

Rules of inheritance -

Depending on the value of visibility-mode, multiple inheritance can be performed in various ways -

Please subscribe our social media channels for notifications, we post a new article everyday.

Decodejava Google+ Page Decodejava Facebook Page  DecodeJava Twitter Page

Coming Next