10 ms·
> They really should just use a simpler example, like 10_000_000 being easier to read as "10 million" than 10000000. Declarations such as `$million = 1000 * 10
by dotancohen 5y ago
> They really should just use a simpler example, like 10_000_000 being easier to read as "10 million" than 10000000.
Declarations such as `$million = 1000 * 1000;` or `$seconds_in_day = 24 * 3600;` are very common, and in my opinion more readable than the ignored-underscore syntax.
- tyingq 5y agoPerhaps, though the underscore syntax works in Perl, Ruby, Java, etc. And the context here is how to explain it, not whether it should exist and/or be used.