求大神!错在哪?
#include <stdio.h>int main()
{
int a[10],high,average,sum;
int i;
printf("Enter 10 students's score: ");
for(i=0;i<10;i++)
{
scanf("%d",a[i]);
}
high=a[0];
sum=a[0];
for(i=0;i<10;i++)
{
sum=sum+a[i];
if(a[i]>high)
high=a[i];
}
average=sum/10;
for(i=0;i<10;i++)
{
if(a[i]>average)
printf("%0.2f\t",a[i]);
}
return 0;