Start: Jul, 06, 2019 10:00:00
20190706Python程序设计基础培训扩展练习
End: Jul, 17, 2019 12:00:00
Time elapsed:
Time remaining:

Problem_ID: C
Result: Accepted
Time: 49ms
Memory: 25184kB
Author: 13115729003
In contest: 1300

a,b=map(int,input().split())
c=[]
for i in range(a):
    c1=list(map(str,input().split()))
    c.append(c1)

for j in range(b):
    d=input()
    for k in range(len(c)):
        if c[k][0]==d:
            e=int(c[k][2])
            if e>=90 and e<=100:
                print("A")
            elif e>=80 and e<90:
                print("B")
            elif e>=70 and e<80:
                print("C")
            elif e>=60 and e<70:
                print("OK")
            elif e<60:
                print("ARE YOU PIG?")