T = int(input()) for t in range(T): H,W,D = map(int,input().split()) ans = 1 if H & 1: if W & 1: if min(H * H + 1, W * W + 1) <= D * D: ans = 0 else: if min(H * H, W * W + 1) <= D * D: ans = 0 else: if W & 1: if min(H * H + 1, W * W) <= D * D: ans = 0 else: if min(H, W) <= D: ans = 0 print(["N","S"][ans])