結果

問題 No.250 atetubouのzetubou
ユーザー Konton7Konton7
提出日時 2019-05-13 14:25:03
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 220 ms / 5,000 ms
コード長 576 bytes
コンパイル時間 77 ms
コンパイル使用メモリ 10,812 KB
実行使用メモリ 7,948 KB
最終ジャッジ日時 2023-09-21 21:39:36
合計ジャッジ時間 4,474 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 133 ms
7,916 KB
testcase_01 AC 35 ms
7,832 KB
testcase_02 AC 193 ms
7,756 KB
testcase_03 AC 220 ms
7,928 KB
testcase_04 AC 188 ms
7,796 KB
testcase_05 AC 198 ms
7,808 KB
testcase_06 AC 153 ms
7,764 KB
testcase_07 AC 82 ms
7,848 KB
testcase_08 AC 181 ms
7,764 KB
testcase_09 AC 142 ms
7,924 KB
testcase_10 AC 197 ms
7,796 KB
testcase_11 AC 124 ms
7,912 KB
testcase_12 AC 178 ms
7,772 KB
testcase_13 AC 104 ms
7,948 KB
testcase_14 AC 16 ms
7,764 KB
testcase_15 AC 96 ms
7,940 KB
testcase_16 AC 97 ms
7,848 KB
testcase_17 AC 98 ms
7,932 KB
testcase_18 AC 98 ms
7,892 KB
testcase_19 AC 98 ms
7,768 KB
testcase_20 AC 15 ms
7,904 KB
testcase_21 AC 15 ms
7,760 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())


def query(inlist):
    d, x, t = inlist

    ans = 1

    def check(y):
        if y > t:
            return -1
        else:
            return 0

    x = x + d - 1
    d = d - 1
    d = min(d,x-d)

    a, b = 1, 1
    check(a//b)
    if  check(a//b) == -1:
        ans = -1

    for i in range(d):
        a *= x-i
        b *= d-i

        if  check(a//b) == -1:
            ans = -1
            break

    if ans == -1:
        print("ZETUBOU")
    else:
        print("AC")
    return

for i in range(n):
    query([ int(v) for v in input().split() ])
0