- 2
please help
Fill in the blanks to calculate the sum of all elements of the array called "num" and output the result to the console. num = [8, 7, 44, 3, 21]; let sum = 0; (let i=0;i<5;i++) { sum += [i]; } .log(
2 Respuestas
+ 1
have you tried this in code-playground?
If not try
hint : you can access array like num[0] is 8 same as num[i] when i is 0
0
The exercises are intended for you to practice and consolidate the lessons. If someone else does them for you, what are you doing the course for?