C语言编程基础.pdfVIP

  • 104
  • 0
  • 约6.01万字
  • 约 60页
  • 2022-08-28 发布于河北
  • 举报
1:第 1题 m 个人的成绩存放在 score数组中,请编写函数fun,它的功能是:将低于平均 分的人作为函数值 回,将低于平均分的分数放在below 所指定的函数中。 答案: int fun (int score [], int m, int below []) ( int i, k=0, aver=0 ; for (i=0 ; i m ; i++) aver+=score [i] ; aver/=m ; for (i=0 ;im ;i++) if (score [i] aver) ( below [k]=score [i] ;

文档评论(0)

1亿VIP精品文档

相关文档