50 Answer
(Choose 1 answer)
What does method M1 do?
public static int M1(int[] A)
int x = 0;
{ foreach (int e in A){}x += e return x;}
A. Method M1 returns the summation of the integer elements in array A.
B. Method M1 prints all elements in A
C. We cannot use foreach statement to iterate over the elements in a one-dimensional array.
D. Method M1 finds the maximum number in the array A.
Elt