Question PRG-JAVA-0045
MediumWhat is the output of this program?
public class Main {
public static void main(String[] args) {
int[] a = {1, 2, 3};
int[] b = {1, 2, 3};
System.out.println((a == b) + " " + a.equals(b) + " " + java.util.Arrays.equals(a, b));
}
}
- A.
true true true
- B.
false false true
- C.
Sign up free to see the answer and a step-by-step explanation.