結果

問題 No.1801 Segment Game
ユーザー titiatitia
提出日時 2022-01-07 22:14:21
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 255 ms / 2,000 ms
コード長 357 bytes
コンパイル時間 380 ms
コンパイル使用メモリ 10,716 KB
実行使用メモリ 8,380 KB
最終ジャッジ日時 2023-08-09 06:01:26
合計ジャッジ時間 3,805 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,880 KB
testcase_01 AC 246 ms
8,176 KB
testcase_02 AC 247 ms
8,260 KB
testcase_03 AC 243 ms
8,380 KB
testcase_04 AC 239 ms
8,260 KB
testcase_05 AC 235 ms
8,220 KB
testcase_06 AC 234 ms
8,252 KB
testcase_07 AC 255 ms
8,340 KB
testcase_08 AC 254 ms
8,308 KB
testcase_09 AC 245 ms
8,312 KB
testcase_10 AC 15 ms
7,868 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline

T=int(input())
for tests in range(T):
    H,W,D=map(int,input().split())

    if H*H+W*W<=D*D:
        print("N")
    elif H%2==0 and W<=D:
        print("N")
    elif W*W+1<=D*D:
        print("N")
    elif H*H+1<=D*D:
        print("N")
    elif W%2==0 and H<=D:
        print("N")
    else:
        print("S")
    
0