九州体育网 - 十年信誉网站

关于作者

Discuss / JavaScript / 作业

作业

Topic source

从未挣脱43268

#1 Created at ...

function sum(...rest) { var sum=0; for(var i of rest){ sum+=i; } return sum; }

从未挣脱43268

#2 Created at ...

function sum(...rest) { var sum=0; rest.forEach(function(e){ sum+=e; }); return sum; }


  • 1

Reply

WARNING: You are using an old browser that does not support HTML5. Please choose a modern browser (Chrome / Microsoft Edge / Firefox / Sarafi) to get a good experience.