
#WHICHDIV

# cook your dish here
try:
    for _ in range(int(input())):
        r=int(input())
        if r>=2000:
            print("1")
        elif r>=1600:
            print("2")
        else:
            print("3")
except:
    pass