Hacker News new | past | comments | ask | show | jobs | submit login

You seem to be saying that circles are not subtypes of ellipses. That circleness is just a property of ellipses. If we accept that then the whole issue is moot, and substitutability is true by tautology.

A circle is a triple: (x,y,radius). An ellipse is a 5-tuple: (x,y,major,minor,angle).

Maybe we should be talking about angle instead? It can't be derived from a circle. What happens when you feed a circle to selectEllipsesByAngle()?




If isEllipseAtAngle(someAngle): boolean were a method, a Circle type could return true for every angle.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: