var foo = 1; function bar() { foo = 10; return; function foo() {}//聲明提早 } bar(); console.log(foo); //爲何是1而不是10
http://segmentfault.com/q/1010000000598752segmentfault