T=int(input()) for i in range(T): x=int(input()) print('N' if x!=45 and x!=0 else 'Y')