- Exercise
In this lesson, we'll look at a few cases of inheritance's core guidelines and try to solve them on our own.
We'll cover the following
Try it! #
A class hierarchy is constructed to represent a set of hierarchically organized concepts (only). Typically, base classes act as interfaces. There are two major uses for hierarchies, often named implementation inheritance and interface inheritance.
Read the class hierarchy rules in the given links:
C.120: Use class hierarchies to represent concepts with inherent hierarchical structure (only)
C.121: If a base class is used as an interface, make it a pure abstract class
Get hands-on with 1400+ tech skills courses.