📅  最后修改于: 2022-03-11 15:03:10.637000             🧑  作者: Mango
function add (...numbers) {
let sum = 0;
for (let i = 0; i < numbers.length; i++) {
sum += numbers[i]
};
console.log(sum);
};
add(2, 3);
add(5, 3, 7, 2);