By what stretch of the imagination is this a "snippet"?
Did you even read Where should I post X?
Looking @ it from a _great_ (no; I mean really great. Greater than that even...) distance this looks just like a snippet...
I like what your doing - even though you posted it in the wrong place... ;->
Adding some configuration mechanism seems like something you want to do since all your checks are now hard coded and most can quite easily become soft coded.
0 - I'm a blankster
0 - My devices have no keyboard
0 - I use a chorded keyboard that transcends your concept of keys
26 - I need the other keys for Perl sigils!
31 - I write code in the original APL
31 - ß counts only as one letter!
∞ - I use an Optimus keyboard
ℵ1 - I reject your Latin-centric notion of letters
Results (28 votes),