def solve(): h, w, d = map(int, input().split()) d *= d if w % 2 == 0: min_ = h * h else: min_ = h * h + 1 if h % 2 == 0: min_ = min(min_, w * w) else: min_ = min(min_, w * w + 1) if min_ <= d: print("N") else: print("S") for _ in range(int(input())): solve()