Generating the alphabet in JavaScript I'm pretty sure there's not a better way to do this but figured it couldn't hurt to ask.

I'm tired of typing out a='abcdefghijklmnopqrstuvwxyz'.

Cool languages have Range('a'..'z') or similar

What can we come up with with JS that's as short as possible??

for(i=97,a='';i&lt;123;){a+=String.fromCharCode(i++)}


is longer than just the alphabet - but guarantees I don't screw up somewhere.

I'm hoping there's a nasty bit-shifty way to produce a-z in less than 50 characters.

I messed around with i=97;Array(26).map(x=&gt;String.fromChar....i++

but it was always way longer by the time I joined then split the array(26) to be useable



Edit: I've gotten it down to 

[...Array(26)].reduce(a=&gt;a+String.fromCharCode(i++),'',i=97)


60 bytes
Alternative to String.fromCharCode
... if you are happy with a lowercase only alphabet.

for(i=9,a='';++i&lt;36;)a+=i.toString(36) // 38, cannot be used in an expression
[...Array(26)].map(_=&gt;(++i).toString(36),i=9).join`` // 52 directly returnig the string desired
[...Array(26)].map(_=&gt;a+=(++i).toString(36),a='',i=9) // 53 assign to a variable
(i=9,[for(_ of Array(26))(++i).toString(36)].join``) // 52 ES7 direct return
i=9,a='',[for(_ of Array(26))a+=(++i).toString(36)] // 51 ES7 assign to a variable