contains the concept of Inheritance . Introduction to Inheritance Inheritance is one of the most important features of Object Oriented Programming. In object-oriented programming, inheritance enables new class and its objects to take on the properties of the existing classes. A class that is used as the basis for creating a new class is called a superclass or base class.
A class that inherits from a superclass is called a subclass or derived class . Need for Inheritance Inheritance is an important feature of object oriented programming used for code reusability. It is a process of creating new classes called derived classes, from the existing or base classes. Inheritance allows us to inherit all the code (except declared as private) of one class to another class.
The class to be inherited is called base class or parent class and the class which