...
include<stdio.h>
int main()
{
int i,count=0;
int a[5];
float sum=0,aver;
printf("请输入一些正整数:");
for(i=0;i<N;i++)
{
scanf("%d",&av[i]);
if(av[i]==-1) break;
sum+=av[i];
count++;
}
aver=sum/count;
printf("平均数为%.2f\n",aver);
printf("大于平均数的数有: ");
for(i=0;i<=count;i++){
if(av[i]>aver)
printf("%d ",av[i]);
}
printf("\n");
}