Hi, I’m having trouble with this exercise. My code is like that:
var myArr = [ 2, 3, 4, 5, 6];
var myTotal = 0;
for (var i = 0; i < myArr.length; i++) {
myTotal += myArr[i];
}
Is still returning the error that total should equal 20 and declared and initialized to 0.
Any help?