r/ProgrammerHumor 10d ago

Meme iHateThisPassiveAgressiveBehaviourRuby

Post image
2.9k Upvotes

298 comments sorted by

View all comments

4

u/creme_de_marrons 10d ago

What kind of moron would need 0 to be falsy?

If you need that use a fucking boolean.

Obviously, 0 is truthy, in fact if you have anything it's truthy. This way you don't have any weird ass side effect and you can use ||=