結果

問題 No.1801 Segment Game
ユーザー ShirotsumeShirotsume
提出日時 2022-01-07 22:57:52
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 154 ms / 2,000 ms
コード長 316 bytes
コンパイル時間 321 ms
コンパイル使用メモリ 86,856 KB
実行使用メモリ 78,240 KB
最終ジャッジ日時 2023-08-09 06:06:01
合計ジャッジ時間 3,101 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 71 ms
71,324 KB
testcase_01 AC 146 ms
77,772 KB
testcase_02 AC 144 ms
77,892 KB
testcase_03 AC 145 ms
77,592 KB
testcase_04 AC 150 ms
78,240 KB
testcase_05 AC 145 ms
77,852 KB
testcase_06 AC 150 ms
77,460 KB
testcase_07 AC 148 ms
78,204 KB
testcase_08 AC 152 ms
78,216 KB
testcase_09 AC 154 ms
77,860 KB
testcase_10 AC 69 ms
71,276 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = lambda: sys.stdin.readline().rstrip()
INF = 10 ** 19

def solve():
    h, w, d = map(int,input().split())
    ans = None
    if pow(w, 2) + h % 2 <= d * d or pow(h, 2) + w % 2 <= d * d:
        ans = 'N'
    else:

        ans = 'S'
    print(ans)


t = int(input())
for _ in range(t):
    solve()
0