CJCoding With Joseph
15free / daySign inCreate account
Back to Multiple Choice Quiz

Select topics to narrow your question pool, then enable Random to jump to a random question matching your filters.

Topics

Array Aliasing

Java quiz · Question 19
mediumArrays

What is printed?

Code

1import java.util.Arrays;
2 
3public class Main {
4 public static void main(String[] args) {
5 int[] a = {2, 4, 6};
6 int[] b = a;
7 
8 b[0] = 9;
9 
10 System.out.println(Arrays.toString(a));
11 }
12}