public static void main(String[] args) { int[][] a = { {1,2,3},{4,5,6},{7,8,9}}; printlnA(a);}public static void printlnA(int[][] a){ int size = a.length; int len = 2*a.length-1;//一共生成几行结果 for(int k=0;k
结果为
3,
2,6, 1,5,9, 4,8, 7,
本文共 295 字,大约阅读时间需要 1 分钟。
public static void main(String[] args) { int[][] a = { {1,2,3},{4,5,6},{7,8,9}}; printlnA(a);}public static void printlnA(int[][] a){ int size = a.length; int len = 2*a.length-1;//一共生成几行结果 for(int k=0;k
结果为
3,
2,6, 1,5,9, 4,8, 7,
转载于:https://my.oschina.net/u/3410701/blog/994003