TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Most Pressed Keys and Programming Syntaxes

94 pointsby talmirzaalmost 13 years ago

25 comments

sltkralmost 13 years ago
I admit, the Lisp one at the end made me laugh.<p>For most other languages the focus seems to be mainly on letters (typing out keywords/identifiers), so in that sense there is little evidence that one language would be easier to write than another.<p>Additionally, I imagine that some of the code is auto-completed by an IDE, which this analysis fails to account for.
评论 #4233685 未加载
评论 #4232883 未加载
评论 #4233013 未加载
评论 #4232831 未加载
kjhughesalmost 13 years ago
If this were actual keys pressed while programming rather than an analysis of completed code, the action on app switch and editor meta-keys would rival that of the highest ranking regular keys.
the_cat_kittlesalmost 13 years ago
It would be nice to see these heat maps normalized by the average frequency of each key. Then you can really see what stands out about each particular language.
评论 #4233414 未加载
citricsquidalmost 13 years ago
<i>Vaguely</i> related, if anyone is interested in tracking their own typing (and individual key counts) check out <a href="http://whatpulse.org" rel="nofollow">http://whatpulse.org</a> it's pretty great :-) (my profile, <a href="http://whatpulse.org/stats/users/210575/" rel="nofollow">http://whatpulse.org/stats/users/210575/</a>)
评论 #4233063 未加载
alpbalmost 13 years ago
I skimmed comments here and couldn't find anything that talks about why e is so popular? Is it because ETAOIN? Because almost no "{" "}" pressed in C/Java. Almost no ":" used in Python. "/" key is more popular than "[" "]" in Objective-C. This makes no sense. I don't believe that blog post.
评论 #4233795 未加载
评论 #4233693 未加载
评论 #4233739 未加载
simiasalmost 13 years ago
I would like to see what a heatmap generated from a "real" typing session would look like (with a keylogger). You could see the influence of the editor as well.<p>Since these are generated offline, the keyboard heatmaps are meaningless and the representation is slightly misleading IMO.
schmealmost 13 years ago
A live sample would be much more interesting, both would be best. I'd be most interested in the meta keys. As a scandinavian especially {}, [] etc. buttons are very awkward to press. Infact, so are most special characters used in programming.<p>As mentioned, auto-complete and similar functionality change the heatmap, but that's what people actually press. This data would be alot better for actual use.<p>Though I don't mean it as a scold, it wasn't really in the hands of the author to collect such vast amounts of live data, and surely a lot more work than was his intension.
mattparlanealmost 13 years ago
It's not really measuring "pressed keys", it's measuring a final product -- I'd be interested to see which languages highlight the backspace/delete keys more.
eddie_the_headalmost 13 years ago
I'd be interested in seeing which keys I press most when I'm programming in APL.
评论 #4233054 未加载
einhverfralmost 13 years ago
Next bit would be interesting to look at hand position of programmers in different languages. I know when I am programming Perl my right hand tends to move back and forth into different positions while my left hand stays in the standard position. Wondering if I am unique there or if it is common, and how other languages affect this.
joestringeralmost 13 years ago
I'd be curious to see the same analysis done but with alternate keyboard layouts, such as dvorak or colemak.
评论 #4233826 未加载
nixalmost 13 years ago
"Shift" is a big omission, though you can guess at it from the emphasis on certain numeric keys. One of the great things about Python is that there are fewer chorded characters. It's also one of the worst things about Lisp on a standard keyboard.
评论 #4233380 未加载
nkorenalmost 13 years ago
Interesting, but a different visualisation would be even more interesting: heat maps showing deviations from the mean. This would highlight the differences between the languages, which (except for the case of Lisp) are rather subtle.
tunnuzalmost 13 years ago
It would be nice to consider how auto-completion actually biases the real distribution of key-presses, e.g. I wouldn't expect closing parenthesis or brackets to be pressed as often as their opening counterparts.
mahmudalmost 13 years ago
Not if you're an emacs user. I use key-chords most programming language forms.<p>Also, for Lisp, I never touch the closing paren. M-( does both at the same time.
godDLLalmost 13 years ago
Here are the keys directly under my fingers on the home row: A R S T N E I O<p>And I can visually see the reasoning behind Colemak being like this, now.
iamwilalmost 13 years ago
It'd be useful to use the histograms to distinguish between different programming languages for automatic language detections of something like gists.
评论 #4234521 未加载
philwelchalmost 13 years ago
Interesting how "i" is more common in some languages than others. C and C++ make sense (for(i = 0; i &#60; n; i++)), but Ruby is a puzzler.
评论 #4233321 未加载
jakejakealmost 13 years ago
I can understand 0 and 1 being frequently used. But I wonder why 5,6 &#38; 7 seem to be under-used compared to the other numbers?
评论 #4233090 未加载
评论 #4233110 未加载
评论 #4233079 未加载
DeepDuhalmost 13 years ago
What looks strange to me is that semicolon is is not one of the most common in C-derived languages.
PerryCoxalmost 13 years ago
Why is E the most common across multiple languages (except Lisp (which I assume is due to the parentheses))? I assume it's usage is higher because it's a vowel, but none of the other vowels are nearly that high.
评论 #4232862 未加载
评论 #4232885 未加载
cstavishalmost 13 years ago
What kind of C programming is this guy doing? '*' is relatively untouched.
评论 #4233654 未加载
AndyKelleyalmost 13 years ago
Dear author: would you consider also generating the results for Dvorak?
评论 #4234429 未加载
cpetersoalmost 13 years ago
I wonder what a programming language designed to minimize shifting would look like. Python does a pretty good job because it uses few curly brackets and no semicolons.
评论 #4233301 未加载
stigialmost 13 years ago
Gotta say, I expected more square brackets for Objective-C.