Skip to content

Comment on Most Pressed Keys and Programming Syntaxesparent

Comments

One question is why the Lisp code doesn't use the letter E as much as every language? Is that just due to normalizing of parentheses?

While I do not know standard lisp, according to my memory of scheme the following list of c keywords containing the letter 'e' exist in scheme: while.

while the following do not: break, case, continue, default, double, else, enum, extern, register, return, signed, sizeof, typedef, unsigned, volatile

It probably gets used about the same amount as the other languages, it's just that the parentheses get used an insane amount and outweigh all the other characters.

It might be more interesting to see these with the vowels factored out.

  ~ $ curl -s 'http://lib.store.yahoo.net/lib/paulgraham/onlisp.lisp' | egrep -o '.' | sort | uniq -c | sort -nr
  18641  
  3277 )
  3276 (
  2561 e
  2159 a
  1934 s
  1903 r
  1672 n
  1661 t
  1477 l
  1380 o
  1287 c
  1282 d
  1067 p
  1064 i
  1030 m
  [...]
Without vowels:
  18641  
  3277 )
  3276 (
  1934 s
  1903 r
  1672 n
  1661 t
  1477 l
  1287 c
  1282 d
  1067 p
  1030 m
   929 f
   852 b
   654 ,
   601 g
  [...]

> 3277 ) > 3276 (

My first thought: 'unmatched paren?'

But I bet there's a smiley face on that page somewhere.

EDIT: If there is, I don't see it.

  (let ((rpar (get-macro-character #\) )))
Escaped. :)
AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.