re: What’s an unpopular software opinion you have? VIEW POST

FULL DISCUSSION
 

Inheritance is 99.9% of the time (e.g. always...) the wrong decision.

Inheritance, after-all, is one of the strongest forms of coupling you can introduce into your code ;)

There's usually a way to use composition to achieve the same thing.

 

Agreed.

Composition is 99% of the times a better choice :D

 
 

Yeah, I kind of wish that hadn’t been such a big part of my formal education.

I only did some CS and so much of it revolved around inheritance in Java that I found myself looking for opportunities to use inheritance in the wrong places.

 
 

James, didn't you do a Composition over inheritance post?

 

I don't think so... but it's something I've had in my head to do someday!

 
code of conduct - report abuse