成绩转换

Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 70452    Accepted Submission(s): 30852

Problem Description
输入一个百分制的成绩t,将其转换成对应的等级,具体转换规则如下:
90~100为A;
80~89为B;
70~79为C;
60~69为D;
0~59为E;
 
Input
输入数据有多组,每组占一行,由一个整数组成。
 
Output
对于每组输入数据,输出一行。如果输入数据不在0~100范围内,请输出一行:“Score is error!”。
 
Sample Input
56
67
100
123
 
Sample Output
E
D
A
Score is error!
 
Author
lcy
#include<stdio.h>
int main()
{
int n;
while(scanf("%d", &n) == )
{
if(n>=&&n<=)
printf("A\n");
if(n>=&&n<=)
printf("B\n");
if(n>=&&n<=)
printf("C\n");
if(n>=&&n<=)
printf("D\n");
if(n>=&&n<=)
printf("E\n");
if(n<||n>)
printf("Score is error!\n");
}
return ;
}

HDOJ2004成绩转换的更多相关文章

  1. hdu 2004 成绩转换

    成绩转换 Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submi ...

  2. 成绩转换 AC 杭电

    成绩转换 Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submi ...

  3. 杭电OJ2004——成绩转换

    /*成绩转换Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submi ...

  4. HDOJ2004_成绩转换

    水题:用数组标识各个阶段分数的等级即可. HDOJ2004_成绩转换 #include<stdio.h> #include<stdlib.h> #include<math ...

  5. hdu2004 成绩转换【C++】

    成绩转换 Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submis ...

  6. 【ACM】hdu_2004_成绩转换_201307261516

    成绩转换Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submiss ...

  7. 练习2 C - 成绩转换

    Time Limit:1000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64u   Description 输入一个百 ...

  8. 2004 ACM 成绩转换 两种方法

    题目:http://acm.hdu.edu.cn/showproblem.php?pid=2004 中文题目,简单题. 题意:将分数转换成ABC制 查表法 #include <stdio.h&g ...

  9. NYOJ题目98成绩转换

    aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAsQAAAJhCAIAAADJ5jGJAAAgAElEQVR4nO3dq3LkSPg36O8mzH0hxn ...

随机推荐

  1. [转]sql server 数据库日期格式化函数

    转至:http://www.cnblogs.com/hantianwei/archive/2009/12/03/1616148.html 0   或   100   (*)     默认值   mon ...

  2. PAC(Proxy Auto Config)代理自动配置文件的编写

    Proxy Auto Config文件格式说明 PAC文件实际上是一个Script, 通过PAC我们可以让系统根据情况判断使用哪一个Proxy来访问目标网址, 这样做的好处: 分散Proxy的流量,避 ...

  3. SQLite内存数据库

    [转]SQLite内存数据库 http://www.cnblogs.com/liuyong/archive/2010/09/14/1826152.html SQLite 介绍 一. SQLite 是实 ...

  4. 字符串匹配 - KMP算法

    #include<cstdio> #include<cstring> #include<cstdlib> void GetNext(char *t,int *nex ...

  5. Android——设计原则(Design Principles)

    Enchant Me Delight me in surprising ways(动画.音效...) Real objects are more fun than buttons and menus( ...

  6. CDOJ 482 Charitable Exchange bfs

    Charitable Exchange Time Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://acm.uestc.edu.cn/#/problem/s ...

  7. STM8的wait for interrupt

    如果我用disable interrupt和enable interrupt包裹wait forinterrupt(WFI).你说WFI还能被唤醒么?有思考过么? 昨晚拿STM8L151K4的开发板, ...

  8. 史上最浅显易懂的Git教程!

    http://www.liaoxuefeng.com/wiki/0013739516305929606dd18361248578c67b8067c8c017b000

  9. Android多媒体数据库之MediaStore研究

    应网友要求,今天给大家讲android的多媒体数据库.MediaStore这个类是android系统提供的一个多媒体数据库,android 中多媒体信息都可以从这里提取.这个MediaStore包括了 ...

  10. C#二维数组(矩形数组,交错数组)

    C# 支持一维数组.多维数组(矩形数组)和数组的数组(交错的数组) 1.多维数组 声明:string[,] names; 初始化:int[,] numbers = new int[3, 2] { {1 ...