How do you instantiate an array in Java?

Q & AHow do you instantiate an array in Java?
Admin Staff asked 4 years ago

How do you instantiate an array in Java?
a) int arr[] = new int(3);
b) int arr[];
c) int arr[] = new int[3];
d) int arr() = new int(3);

1 Answers
Admin Staff answered 4 years ago

c) int arr[] = new int[3];