varname="小明",person={name:"小紅",getName:function(){ returnfunction(){ returnthis.name; };}};console.log(person.getName()());//小明為什么最后打印出來的“小明”而不是“小紅”?看不太懂person.getName()()這句后面兩個括號的意思。//新手勿噴,謝謝
請幫忙解釋一道關于this的面試題?
慕少森
2019-05-12 14:16:58
