我的问题是我们可以以这种热情声明数组
int college[][][];
它包含 3 个模块:部门、学生、分数
我需要一个系 5 名学生和另一系 6 名学生
我们可以这样声明数组吗?如果是这样怎么办?
最佳答案
int college[][][] = new int[3];
college[0] = new int[5];
college[1] = new int[6];
...
college[0][0] = new int[count_marks_dept1_student1];
关于java - java中不同长度的数组的数组,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18488977/