Which of the following creates a jagged array in Java?
Correct answer
int[][] arr = new int[2][];
Explanation
Option B creates an array of 2 rows without specifying column size (jagged array).
Update: Admin added a tag on this question
Topics
By Admin · · 22 views