重写练习
Hei,candy
这个作者很懒,什么都没留下…
展开
-
重写Array.prototype.foreach
Array.prototype.foreach和Array.prototype.map的区别是foreach返回值是undefined Array.prototype.forEach = function forEach(callback) { var self = this, arr = [], i = 0; if (typeof callback !== "function") throw new TypeError('callback must be a原创 2020-12-18 09:37:19 · 282 阅读 · 0 评论 -
重写Array.prototype.map()
第一次 第二次 第三次原创 2020-12-17 09:16:03 · 204 阅读 · 0 评论