結果
| 問題 | 
                            No.1904 Never giving up!
                             | 
                    
| コンテスト | |
| ユーザー | 
                             H20
                         | 
                    
| 提出日時 | 2022-04-15 21:26:20 | 
| 言語 | PyPy3  (7.3.15)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 42 ms / 2,000 ms | 
| コード長 | 189 bytes | 
| コンパイル時間 | 175 ms | 
| コンパイル使用メモリ | 82,428 KB | 
| 実行使用メモリ | 59,264 KB | 
| 最終ジャッジ日時 | 2024-12-24 23:25:21 | 
| 合計ジャッジ時間 | 1,360 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge3 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 9 | 
ソースコード
import math
import collections
N = int(input())
A = list(map(int, input().split()))
ans = math.factorial(N)
for k,v in collections.Counter(A).items():
    ans//=math.factorial(v)
print(ans)
            
            
            
        
            
H20