Skip to main content
Library homepage
 

Text Color

Text Size

 

Margin Size

 

Font Type

Enable Dyslexic Font
Engineering LibreTexts

13.0: Introduction

( \newcommand{\kernel}{\mathrm{null}\,}\)

sheep with lamb
Figure 13.1 credit: modification of work "Don't stare...only sheep dogs stare...", by Bernard Spragg. NZ/Flickr, Public Domain

Real-world entities are often described in relation to other entities. Ex: A finch is a type of bird. Similarly, classes, which represent types of real-world entities, can be related to each other.

Inheritance describes the relationship in which one class is a type of another class. Classes within inheritance relationships can inherit attributes and methods from other classes without needing to redefine everything. Thus, inheritance in object-oriented programming reduces redundancy and promotes modularity.


This page titled 13.0: Introduction is shared under a CC BY 4.0 license and was authored, remixed, and/or curated by OpenStax via source content that was edited to the style and standards of the LibreTexts platform.

Support Center

How can we help?