Solved

Assume the Method CreateSomething Has Been Defined as Follows

Question 44

Multiple Choice

Assume the method createSomething has been defined as follows:
Int [] createSomething (int start, int size)
{
Int [] result = new int[size];
For (int i = 0; i < result.length; i++)
{
Result[i] = start;
Start++;
}
Return result;
}
What is printed by the statement below?
System.out.print (Arrays.toString(createSomething(4, 3) ) ) ;


A) [3, 4, 5, 6]
B) [4, 4, 4]
C) [3, 3, 3, 3]
D) [4, 5, 6]

Correct Answer:

verifed

Verified

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

Related Questions