T = int(input()) for _ in range(T): """対象となる線を引けたら価値""" H, W, D = map(int, input().split()) cand = [] if H % 2 == 0: cand.append(W * W) else: cand.append(W * W + 1) if W % 2 == 0: cand.append(H * H) else: cand.append(H * H + 1) if min(cand) <= D * D: print("N") else: print("S")