#include "stdafx.h"#include <iostream>
using namespace System;
int main(){
int m[4][5]={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19}; int n; int sum1=0,sum2=0,sum3=0;
for(int i=0;i<4;i++) for(int j=0;j<5;j++){ if(i==j) sum1+=m[i][j]; else if (j<i)sum2+=m[i][j]; else sum3+=m[i][j];
}
printf("%d %d %d",sum1,sum2,sum3); return 0;}
#include "stdafx.h"
#include <iostream>
using namespace System;
int main()
{
int m[4][5]={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19};
int n;
int sum1=0,sum2=0,sum3=0;
for(int i=0;i<4;i++)
for(int j=0;j<5;j++){
if(i==j) sum1+=m[i][j];
else if (j<i)sum2+=m[i][j];
else sum3+=m[i][j];
}
printf("%d %d %d",sum1,sum2,sum3);
return 0;
}