Array.prototype.with和arr下标赋值性能对比 歪脖砖家 2024-02-01 33 阅读1分钟 Array.prototype.with(i,0) VS arr[i]=0 性能对比: 话不多说,直接上代码: 可以观察到直接赋值的效率更高: