求大神解析一下怎么用循环嵌套多维数组
import java.util.*;public class A5_10{
public static void main(String []args){
Scanner in=new Scanner(System.in);
String [][] arr=new String[3][];
arr[0]=new String[2];
arr[1]=new String[2];
arr[2]=new String[2];
for(int i=0;i<=arr[0].length-1;i++){
System.out.println("请输入姓名:");
arr[0][i]=in.next();
}
for(int i=0;i<=arr[1].length-1;i++){
System.out.println("请输入姓名:");
arr[1][i]=in.next();
}
for(int i=0;i<=arr[2].length-1;i++){
System.out.println("请输入姓名:");
arr[2][i]=in.next();
}
for(int i=0;i<=arr[0].length-1;i++){
System.out.print(arr[0][i]+"\t");
if(i==1){
System.out.println();
}
}
for(int i=0;i<=arr[1].length-1;i++){
System.out.print(arr[1][i]+"\t");
if(i==1){
System.out.println();
}
}
for(int i=0;i<=arr[2].length-1;i++){
System.out.print(arr[2][i]+"\t");
if(i==1){
System.out.println();
}
}
}
}