Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Inheritance Often Doesn't Make Sense. Parent comment
Intuitively it makes sense, but practically... What if your function wants to set the width and the height to different values?
This is valid for a rectangle, not for a square.
From a mathematical perspective, a square might be a rectangle. From a software standpoint, it's not.
The reason for the discrepancy between mathematics and programming?
Mutability.
There are no comments on this comment yet.
Intuitively it makes sense, but practically... What if your function wants to set the width and the height to different values?
This is valid for a rectangle, not for a square.
From a mathematical perspective, a square might be a rectangle. From a software standpoint, it's not.
The reason for the discrepancy between mathematics and programming?
Mutability.