from sys import stdin t, *indata = map(int, stdin.read().split()) offset = 0 for i in range(t): h, w, d = indata[offset + 3*i],indata[offset + 3*i+1],indata[offset + 3*i+2] if h * h + 1 <= d * d: print("N") elif w * w + 1 <= d * d: print("N") elif (h % 2 == 0) & (w <= d): print("N") elif (w % 2 == 0) & (h <= d): print("N") else: print("S")