#include<stdio.h>
int main(void)
{
intcount ,sum,aninterger;
printf("enterthe interger anf terminute with negtive number\n");
count=0;
sum=0;
printf("enternumber %d:\n",count+1);
scanf("%d",&aninterger);
while(aninterger>&&aninterger!='\n')
{
sum+=aninterger;
count++;
printf("enter number%d:\n",count+1);
scanf("%d",&aninterger);
}
if(count!=0)
printf("theaverage is %f\n",sum/(double)count);
else
printf("youshuru 了一个wronginterger\n");
return0;
}