Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I can understand 0 and 1 being frequently used. But I wonder why 5,6 & 7 seem to be under-used compared to the other numbers?


I was thinking the same thing until I looked at Perl, which has 4 being quite frequent.

The reason, of course, is that 4 is also $, which is used to denote a scalar in Perl.

Thus, because 5,6,7 correspond to %,^,&, which generally get used to a lesser degree for things like modulo, hashes, exponentiation and logical-and, they're used less.


> I can understand 0 and 1 being frequently used. But I wonder why 5,6 & 7 seem to be under-used compared to the other numbers?

The heat map isn't accounting for shift. 5,6,7 also include %,^,&


I would wager that it is because when creating named variables, people tend to start with the low integers, like var1, var2, etc... And when using constants, they will often use maximums up to a threshold, like 999.99. So the middle range (5-8) is rarely used.




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

Search: