結果

問題 No.1904 Never giving up!
ユーザー hir355hir355
提出日時 2022-04-15 21:28:30
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 91 ms / 2,000 ms
コード長 202 bytes
コンパイル時間 267 ms
コンパイル使用メモリ 87,016 KB
実行使用メモリ 71,876 KB
最終ジャッジ日時 2023-08-26 07:31:25
合計ジャッジ時間 2,143 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 85 ms
71,680 KB
testcase_01 AC 86 ms
71,460 KB
testcase_02 AC 86 ms
71,488 KB
testcase_03 AC 91 ms
71,616 KB
testcase_04 AC 85 ms
71,868 KB
testcase_05 AC 86 ms
71,288 KB
testcase_06 AC 85 ms
71,700 KB
testcase_07 AC 86 ms
71,840 KB
testcase_08 AC 83 ms
71,460 KB
testcase_09 AC 80 ms
71,436 KB
testcase_10 AC 82 ms
71,876 KB
testcase_11 AC 82 ms
71,684 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from math import factorial
from collections import Counter
n = int(input())
a = list(map(int, input().split()))
c = Counter(a)
ans = factorial(n)
for v in c.values():
    ans //= factorial(v)
print(ans)
0