Solved

What Would Be the Results of the Following Code? Int[]

Question 21

Multiple Choice

What would be the results of the following code? int[] array1 = new int[25];
… // Code that will put values in array1
Int value = array1[0];
For (int a = 1; a < array1.length; a++)
{
If (array1[a] < value)
Value = array1[a];
}


A) value contains the highest value in array1
B) value contains the lowest value in array1
C) value contains the sum of all the values in array1
D) value contains the average of the values in array1

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions