Practice: Inheritance in object-oriented PHP
The "Inheritance in object-oriented PHP" tutorial taught us how to use inheritance in order to reduce code duplication. For this aim, we extend the parent class by child classes that use the code from the parent, so we don't need to re-write the code repeatedly in each class. Instead, we need to write the code only once in the parent class and can use it in the child classes.
In the following section, we will be able to practice what we learned about inheritance in PHP by answering some questions and by writing our own code.