题解 | 学生基本信息输入输出
学生基本信息输入输出
https://www.nowcoder.com/practice/58b6a69b4bf943b49d2cd3c15770b9fd
#include<stdio.h> int main() { float c,m,e;//用于接收C、math,English各科的成绩 int s;//用于接收学号 scanf("%d;%f,%f,%f",&s,&c,&m,&e); printf("The each subject score of No. %d is %.2f, %.2f, %.2f.\n",s,round(c * 100) / 100,round(m * 100) / 100,round(e * 100) / 100); return 0; }