Inheritance
In this chapter, we will study inheritance, which is an object-oriented concept that allows us to represent hierarchies.
For example, you might want a class to represent a person. However, you might also want to represent
students and professors. Well, all students are also people and all professors are also people. It
would be nice to store the more general information (like a person’s name and age) in a Person
class, and then create Student and Professor classes that can use the name and age from
Person, and then define more specific features.