Inheritance and Polymorphism
Inheritance is a feature of object-oriented programming that allows a class to inherit properties and methods from another class. The class that is being inherited from is called the parent class or base class, and the class that is inheriting is called the child class or derived class. Inheritance allows the child class to reuse …