I have an exercise to create a function (lets call it "iterateAndSum") which will sum all numbers in array and return the result. I can't use reduce (which is easier). I have to focus on using while loop.
I tried and failed miserably:
function iterateAndSum(arr) {
while (i--) {
e += arr[i];
}
}