这是一道C语言题吗?
it's not hard.
#include
#define N 3
#define M 3
main()
{
int a[N][M],sum[N]={0};
double avg[N];
int i,j;
for(i=0;i
printf("Input the %dth student's scores:",i+1);
for(j=0;j
scanf("%d",&a[i][j]);
sum[i]+=a[i][j];
}
avg[i]=(double)sum[i]/M;
}
printf("The sums are:");
for(i=0;i
printf("\nThe averages are:");
for(i=0;i
printf("\n");
}
你复制过去调试一下看看行不行,如果不是C语言题,您也可以利用EXCEL来解决这个问题。
it's not hard.
#include
#define N 3
#define M 3
main()
{
int a[N][M],sum[N]={0};
double avg[N];
int i,j;
for(i=0;i
printf("Input the %dth student's scores:",i+1);
for(j=0;j
scanf("%d",&a[i][j]);
sum[i]+=a[i][j];
}
avg[i]=(double)sum[i]/M;
}
printf("The sums are:");
for(i=0;i
printf("\nThe averages are:");
for(i=0;i
printf("\n");
}
//ok i wish it will be help.
运用excel表格中的公式栏目下的求和功能和平均数功能即可,选中一个学生的所有科目成绩,拖到最底部,点击公式中的自助求和即可