
static Random rand = new Random();
static int pRand(int mod){
return Math.abs(rand.nextInt())%mod+1;
}
public static vood main(String[] args){
int[][] a = {{1,2,3},{4,5,6}};
for(int i = 0;i
}
}
Integer[][] a1 = {{new Iteger(1)},new Integer(2)},
{new Integer(3),new Integer(4)},
{new Integer(5),new Integer(6)}
};
for(int i = 0; i
}
}
Integer[][] a2;
a2 = new Integer[3][];
for(int i = 0;i
for(int j = 0;j
}
}
for(int i = 0;i
}
}
}
}
以上为程序源代码,请专家看看,问题出在哪里,我JAVAC了几遍都不行,自己初学实在看不出问题在哪里,大家也可推荐下JAVA初学者的论坛给我,谢谢大家了
/6 : public static vood main(String[] args){
/7 : int[][] a = {{1,2,3},{4,5,6}};
/8 : for(int i = 0;i
/10: System.out.println("a["+i+"]"+"["指裂+j+"] :"+a[i][j]);
/11: }
第9行 进行更返逗扮改。
我觉得没有这样的必要啊,实际引用当中几乎不用的。