Daily Prompt: Inheritance

Daily Prompt: Inheritance

Remember when I mentioned I was in the software industry, well sometimes I am a tech geek lol. Today is one of those days. The word of the day is Inheritance. When I think of inheritance I think of inheritance of classes in Object-Oriented programming.

 

In non-technical terms, inheritance is defined as:

  • the action of inheriting
  • ownership by virtue of birthright; the right to inherit
  • anything received as if by inheritance from a predecessor
  • any characteristic passed on by heredity

 

In Technical terms, inheritance is defined as:

  • the process by which an object acquires the some/all properties of another object.

For example, dogs, fish, and cats are types of pets. Therefore we can assume that the class is Pet and the subclasses are dogs, cats, and fish. In this case, the dog, cat, and fish acquire the properties of the class Pet. Dog acquires these properties from Pet and has specific properties of its own, which are different from the classifications of Pet such as breed.

 

An example diagram of inheritance

Software development does not have to be intimidating, some of the concepts in programming are concepts we apply in our everyday lives. We classify dogs as pets, therefore, we have described a mild example of inheritance.

via Inheritance


4 thoughts on “Daily Prompt: Inheritance”

  • 1
    Martel Shorter on December 14, 2017 Reply

    Interesting! I wonder if there are other fields that use this inheritance concept. 🤔

    • 2
      livingwithBrittnee on December 14, 2017 Reply

      Thank you! What do you mean by fields?

      • 3
        Martel Shorter on December 14, 2017 Reply

        When I said fields I was referring to career domains such as medicine, architecture, music, engineering etc

        • 4
          livingwithBrittnee on December 14, 2017 Reply

          Oh I see, yes inheritance can be seen pretty much any where. For example in medicine, you have different categories of medicine or diagnoses that rolled up into something.

Leave a Reply