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

> The empty string being falsey is... very arbitrary to me.

It's extremely useful in a lot of contexts. The basic logic is that an empty string is an empty container, and empty containers are false, so you can test for them more easily.




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

Search: