摘要:
下面说一下for… in语句。可直接把下面的代码复制到浏览器的控制台或Node环境下去执行。~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//用来快速迭代对象。var o ={name:'dylan',age:24,num:110};for(var test in o){ console.log("o["+test+"]= "+o[test]);}console.log("~~~~~~~~~~~")Object.prototype.getName =function(){return this.n 阅读全文