2 ms·
That's a good point. In the example they give it's not really an issue, since the variables are clearly defined right before the if statement. I still think it'
by baddox 13y ago
That's a good point. In the example they give it's not really an issue, since the variables are clearly defined right before the if statement. I still think it's reasonable and intuitive in most cases, once you're familiar with the "truthiness" of basic data types (e.g. empty arrays, empty strings, empty dicts, and numbers equal to zero are "falsy").