TE
科技回声
首页
24小时热榜
最新
最佳
问答
展示
工作
中文
GitHub
Twitter
首页
Anonymous recursion in 6 lines of Javascript
1 点
作者
arnemart
超过 14 年前
1 comment
lhorie
超过 14 年前
Seems like a somewhat convoluted way of doing this:<p><pre><code> alert(function rec(i) { return i === 0 ? 1 : i * rec(i - 1); }(4));//24 alert(typeof rec);//undefined</code></pre>