結果

問題 No.250 atetubouのzetubou
ユーザー yuppe19 😺yuppe19 😺
提出日時 2015-07-29 18:58:45
言語 PyPy2
(7.3.15)
結果
AC  
実行時間 2,026 ms / 5,000 ms
コード長 370 bytes
コンパイル時間 1,307 ms
コンパイル使用メモリ 77,740 KB
実行使用メモリ 83,296 KB
最終ジャッジ日時 2023-09-24 21:47:12
合計ジャッジ時間 24,628 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1,221 ms
81,652 KB
testcase_01 AC 296 ms
79,436 KB
testcase_02 AC 1,775 ms
81,124 KB
testcase_03 AC 2,026 ms
81,868 KB
testcase_04 AC 1,762 ms
81,092 KB
testcase_05 AC 1,845 ms
81,888 KB
testcase_06 AC 1,451 ms
81,564 KB
testcase_07 AC 780 ms
81,992 KB
testcase_08 AC 1,683 ms
81,216 KB
testcase_09 AC 1,311 ms
82,124 KB
testcase_10 AC 1,812 ms
80,968 KB
testcase_11 AC 1,141 ms
81,536 KB
testcase_12 AC 1,620 ms
82,388 KB
testcase_13 AC 977 ms
81,784 KB
testcase_14 AC 88 ms
78,444 KB
testcase_15 AC 215 ms
81,348 KB
testcase_16 AC 230 ms
83,296 KB
testcase_17 AC 218 ms
83,028 KB
testcase_18 AC 217 ms
82,244 KB
testcase_19 AC 216 ms
81,892 KB
testcase_20 AC 74 ms
76,240 KB
testcase_21 AC 74 ms
76,360 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/python
from operator import mul
def nCr(n, r):
    if r == 0 or n == r:
        return 1
    k = r if r <= n-r else n-r
    return reduce(mul, xrange(n, n-k, -1)) / reduce(mul, xrange(1, k+1))
nHr = lambda n, r: nCr(n+r-1, r)

q = int(raw_input())
for _ in xrange(q):
    d, x, t = map(int, raw_input().split())
    print 'AC' if nHr(d, x) <= t else 'ZETUBOU'
0