public class Egg{
public static void main(String[] args){
int[][] arr = {
{1,2,3,4,5},
{6,7,8,9,10},
{11,12,13,14,15},
{16,17,18,19,20},
{21,22,23,24,25}
};
int sum1 = 0;
for(int i = 0; i < arr.length; i++){
sum1 += arr[i][i];
}
int sum2 = 0;
for(int i = arr.length - 1; i >= 0; i--){
sum2 += arr[arr.length - 1 - i][i];
}
System.out.printf("sum1 = %d, sum2 = %d", sum1, sum2);
}
}