DEV Community

Discussion on: The Four Pillars of Object Oriented Programming

Collapse
 
hsorellana profile image
Hugo Soto

In the example of inheritance, shouldn't dog inherit from Animal instead of Mammal??

Collapse
 
toddster79 profile image
Todd Carlson

Yes, it should! Thank you for bringing that to my attention. I have fixed the mistake. I couldn't initially decide between mammal and animal. Naming things is the hardest part of programming right ; )