• 2022-06-06
    下列程序计算平均成绩并统计90分及以上人数。#include "stdio.h" main() {int n,m; float grade,average; average=n=m=; while() { scanf("%f",&grade); if(grade<0)break; n++; average+=grade; if(grade<90) ; m++; } if(n)printf("%.2f%d ",average/n,m); }