复制过来的代码
前三行没看懂
#include<stdio.h>
int sum(int a,int b,int c,int d);
double average(int a,int b,int c,int d);
int main()
{
int a,b,c,d;
scanf("%d%d%d%d",&a,&b,&c,&d);
printf("Sum=%d\n",sum(a,b,c,d));
printf("Average=%.1lf",average(a,b,c,d));
return 0;
}
int sum(int a,int b,int c,int d)
{
return a+b+c+d;
}
double average(int a,int b,int c,int d)
{
return (a+b+c+d)/4.0;
}