var arr = []; Array.prototype.push = function (){ for(var i= 0;i<arguments.length ; i++){ this[this.length] = arguments[i]; } return this.length } //模仿系统的push方法
js数组
原文:https://www.cnblogs.com/punisher999/p/12270964.html