Practice · 1 of 5
Running total
CHALLENGE
Difficulty: beginner+25 XP
Implement long total(int[] values) returning the sum of all elements. An empty array sums to 0.
Press Submit to check your solution.
Back to lesson: Practice: Practice: Loops
Practice · 1 of 5
Implement long total(int[] values) returning the sum of all elements. An empty array sums to 0.
Back to lesson: Practice: Practice: Loops