标签:function console nbsp logs return add ++ pre 问题
var add; var f1 = function() { var a = 1; add = function() { a++; } function f2() { console.log(a); } return f2; } var t1 = f1(); var t2 = f1(); var t3 = f1(); add(); t1(); // 1 t1(); // 1 t2(); // 2 t2(); // 2 // t3()
标签:function console nbsp logs return add ++ pre 问题
原文地址:http://www.cnblogs.com/ax-null/p/6958799.html