Q. What is the output of the below Java program with arrays?
Code:
public class Polo {
public static void main(String args[])
{
String[] computer = {"RAM","HDD","MOUSE"};
String[] parts = {computer[0],computer[2]};
System.out.print(parts[1]);
}
}
β
Correct Answer: (C)
MOUSE