import sys from sys import stdin tt = int(stdin.readline()) ANS = [] for loop in range(tt): h,w,d = map(int,stdin.readline().split()) ans = "S" if h%2 == 0 and w <= d: ans = "N" if h%2 == 1 and w**2+1 <= d**2: ans = "N" if w%2 == 0 and h <= d: ans = "N" if w%2 == 1 and h**2+1 <= d**2: ans = "N" ANS.append(ans) print ("\n".join(ANS))