1
0
热心网友
let arr = [3, 4, 5, 2, 1]; let sum = arr.reduce((pre, next) => { pre += next; return pre; }, 0) console.log('结果:', sum);
使用道具 举报
本版积分规则 发表回复 回帖并转播 回帖后跳转到最后一页
圆梦公社,专注于为全球华人提供纯粹技术交流的地方,请勿发布任何政治及违法的言论。如有相关侵权、举报、投诉及建议等,请发 E-mail:dzh188@hotmail.com
Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.