Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You have the following C# code. (Line numbers are included for reference only.)
You need the for each loop to display a running total of the array elements, as shown in the following output.
136
10
15
Solution: You insert the following code at line 02:
Does this meet the goal?
A. Yes
B. NO
136 should be in one line, so answer is no
Yes
output is:
1
3
6
10
15
answer is yes
Correct