
Is a Square a Rectangle? What Liskov Taught Me About Inheritance in C#
I'll be honest: when my C# project asked me to make Square inherit from Rectangle, I didn't think twice. A square is a rectangle. We all learned that in primary school. So I wrote class Square : Recta