Below are the answers to a quiz. I would suggest you don't look at the answers until you take the quiz yourself.
http://javascriptweblog.wordpress.com/2010/08/17/a-js1k-byte-saver-quiz/
Below are the answers to a quiz. I would suggest you don't look at the answers until you take the quiz yourself.
http://javascriptweblog.wordpress.com/2010/08/17/a-js1k-byte-saver-quiz/
01. i=f.length;while((n=f[--i]).length);n() | |
02. a.filter(function(i){return i}) | |
03. x=Math.max,n=Math.min,x(a,n(b,c))==b||n(a,x(b,c))==b | |
04. x===!!x | |
05. a=[b,b=a][0] | |
06. n===(n|0) | |
07. Math.max.apply(x,x) | |
08. a.indexOf(b)<0&&a.push(b) | |
09. Array(n+1).join(x) | |
10. a.push.apply(a,b) |