結果

問題 No.250 atetubouのzetubou
ユーザー Konton7Konton7
提出日時 2019-05-13 14:25:03
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 231 ms / 5,000 ms
コード長 576 bytes
コンパイル時間 79 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-07-07 14:54:40
合計ジャッジ時間 4,426 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 20
権限があれば一括ダウンロードができます

ソースコード

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