Answer:
c. 65
Explanation:
The output is 65.
An array of length 10 is created first. Then, the first for-loop fill the array with different values; The array element now become: 2, 3, 4, 5, 6, 7, 8, 9, 10, 11. The array element are generated using the equation a[i] = i + 2; so when i is 0, 1, 2, 3, 4, 5, 6, 7, 8, 9. i must be less than the array length (10).
a[0] = 0 + 2 = 2
a[1] = 1 + 2 = 3
a[2] = 2 + 2 = 4
a[3] = 3 + 2 = 5
a[4] = 4 + 2 = 6
a[5] = 5 + 2 = 7
a[6] = 6 + 2 = 8
a[7] = 7 + 2 = 9
a[8] = 8 + 2 = 10
a[9] = 9 + 2 = 11
result variable is declared and initialized to 0.
The second for-loop goes through the array and add individual element to result.