日期:2014-05-20 浏览次数:20664 次
int [][] score={{1,2,3,4,5,6,7,8,9},{11,22,33,44,55,66,77,88,99},{22,33,44,55,66,77,88,99},{100,200,300,400,500,600,700,800}}; int sum = 0; for(int i = 0;i < score.length;i++){ for(int j = 0;j < score[i].length;j++){ sum += score[i][j]; } } System.out.println(sum);