double fun(double *x)
{ int i, j; double av, y[N];
av=0;
for(i=0; i<N; i++)
/found/
av+=x[i]/N;
for(i=j=0; i<N; i++)
if( x[i]<av ){
y[j]=x[i]; x[i]=-1;
/found/
j++;
}
i=0;
while(i<N)
{ if( x[i]!= -1 ) y[j++]=x[i];
/found/
i++;
}
for(i=0; i<N; i++)x[i] = y[i];
return av;
}
/found/
void fun(char *s, int num[5])
{ int k, i=5;
for(k=0;k<i;k++)
/found/
num[k]=0;
for(;*s;s++)
{ i=-1;
/found/
switch(*s)
{ case ‘a’: case’A’:{i=0;break;}
case ‘e’: case ‘E’:{i=1;break;}
case ‘i’: case ‘I’:{i=2;break;}
case ‘o’: case ‘O’:{i=3;break;}
case ‘u’: case ‘U’:{i=4;break;}
}
if(i>=0)
num[i]++;
}
}
int fun( int a [M][N])
{
int i,j,sum=0;
for(i=0;i<M;i++)
for(j=0;j<M;j++)
if(i0||iM-1||j0||jn-1)
sum+=a[i][j];
return sum;
}
————————————————
版权声明:本文为CSDN博主「Nice 2s you.」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/qq_54638312/article/details/118579723