以下程序段( )的功能是:输入一批整数,用负数作为输入的结束标志,统计其中大于85的数据个数。
A、intcount=0,score;Scanf("%d",&score);While(score>=0){if(score>85){count++;}scanf("%d",&score);}Printf("%d\n",count);
B、Intcount=0,score;Scanf("%d",&score);While(score>=0){scanf("%d",&score);if(score>85){count++;}}Printf("%d\n",count);
C、Intcount=0,score;While(score>=0){scanf("%d",&score);if(score>85){count++;}}Printf("%d\n",count);
D、Intcount=0,score;While(1){scanf("%d",&score);if(score<0)break;if(score>85){count++;}}Printf("%d\n",count);
发布时间:2024-10-21 22:04:10