Skip to content

Comment on Prototype based vs. class based inheritanceparent

Comments

Dynamic and duck typing does help quite a bit there, but I think the default stance of prototypes rather than classes also makes a difference.

The way I write object-centric code in Lua feels very different from in Python, even though both languages are dynamically typed (and otherwise fairly similar). It probably has to do with conventions / what's "Pythonic". I haven't used Ruby enough to comment.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.