T = int(input()) for i in range(T): H, W, D = map(int, input().split()) if H > W: H, W = W, H if D ** 2 >= H ** 2 + (H%2) ** 2: print("N") else: print("S")