输入成绩查看等级
#include<stdio.h>
int main(void)
{
intscore;
chargrade;
while(1)
{
printf("请输入成绩!! ");
scanf("%d",&score);
if(score>=90)
grade='A';
if(score>=80&& score<90)
grade='B';
if(score>=70&&score<80)
grade='C';
if(score>=60&&score<70)
grade='D';
if(score>=50&&score<60)
grade='E';
if(score>=40&&score<50)
grade='F';
printf("您的分数:%d,等级:%c ",score,grade);
}
return0;
}