結果

問題 No.250 atetubouのzetubou
ユーザー rpy3cpprpy3cpp
提出日時 2015-07-24 22:55:45
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 3,031 ms / 5,000 ms
コード長 297 bytes
コンパイル時間 190 ms
コンパイル使用メモリ 10,688 KB
実行使用メモリ 8,476 KB
最終ジャッジ日時 2023-09-22 22:43:20
合計ジャッジ時間 35,245 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1,731 ms
8,240 KB
testcase_01 AC 310 ms
8,284 KB
testcase_02 AC 2,663 ms
8,436 KB
testcase_03 AC 3,031 ms
8,284 KB
testcase_04 AC 2,632 ms
8,336 KB
testcase_05 AC 2,707 ms
8,384 KB
testcase_06 AC 2,110 ms
8,448 KB
testcase_07 AC 1,025 ms
8,464 KB
testcase_08 AC 2,488 ms
8,212 KB
testcase_09 AC 1,881 ms
8,288 KB
testcase_10 AC 2,690 ms
7,884 KB
testcase_11 AC 1,613 ms
8,476 KB
testcase_12 AC 2,453 ms
7,872 KB
testcase_13 AC 1,345 ms
8,376 KB
testcase_14 AC 29 ms
7,908 KB
testcase_15 AC 658 ms
8,252 KB
testcase_16 AC 653 ms
8,352 KB
testcase_17 AC 650 ms
8,276 KB
testcase_18 AC 666 ms
8,276 KB
testcase_19 AC 664 ms
8,440 KB
testcase_20 AC 17 ms
8,024 KB
testcase_21 AC 16 ms
7,912 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import math

def count(D, X):
    if D == 1:
        return 1
    return math.factorial(X + D - 1)//math.factorial(D - 1)//math.factorial(X)

Q = int(input())
for q in range(Q):
    D, X, T = map(int, input().split())
    if count(D, X) <= T:
        print('AC')
    else:
        print('ZETUBOU')
0