# 取れるなら先手は対角線を取る、あとは同じ個数なので先手が勝つ # 先手が対角線を取れない場合、後手が勝つ、D1以上なので先手が一手もできないことはない # いや、対角線でなくていい、中心を通る線の最短のもの T = int(input()) for t in range(T): H, W, D = map(int, input().split()) ans = 'S' shortest_squared = H**2+W**2 if H%2 == 0: shortest_squared = min(shortest_squared, W**2) else: shortest_squared = min(shortest_squared, 1**2+W**2) if W%2 == 0: shortest_squared = min(shortest_squared, H**2) else: shortest_squared = min(shortest_squared, 1**2+H**2) if shortest_squared<=D**2: ans = 'N' print(ans)