1122:0 start-up algorithm 29--rating system time limit:1 Sec Memory limit:64 MB 64bit IO Format:%lld
submitted:2657 accepted:1379
[Submit] [Status] [Web Board] Description
ACM Training Team recruits new players every year. Many of them have practiced since the beginning of their freshman. Of course it started with Hello World, and then a lot of people became cattle people.
Do you want to join? If you are interested, join in soon. Can write email Wu hkust ACM Club [email protected]
Training team implementation of the grading system.
Starting point 1500. Add 5 points to an intensive training session and add 5 points if the top 10
Now enter the number of times a classmate participates and the number of top ten, you give him rank
Grade Level
<1600 D
1600~1699 C
1700~1799 B
>=1800 A
Input
Enter 2 integers, representing the number of participants in the training and the number of top 10 (multiple groups of data)
Output
Output level (one row per set of data)
Sample Input
3 3
Sample Output
D
Source
0 Starting point Learning algorithm
1#include <stdio.h>2 intMain () {3 intn,m;4 while(SCANF ("%d%d", &n,&m)! =EOF) {5 intcout= the+5*n+5*m;6 if(cout< the)7printf"d\n");8 Else if(cout<1700)9printf"c\n");Ten Else if(cout<1800) Oneprintf"b\n"); A Else -printf"a\n"); - } the return 0; -}
1122:0 start-up algorithm 29--grade sub-system