結果
| 問題 | 
                            No.1237 EXP Multiple!
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2020-09-26 11:04:37 | 
| 言語 | PyPy3  (7.3.15)  | 
                    
| 結果 | 
                             
                                RE
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 213 bytes | 
| コンパイル時間 | 170 ms | 
| コンパイル使用メモリ | 82,304 KB | 
| 実行使用メモリ | 263,716 KB | 
| 最終ジャッジ日時 | 2024-06-28 21:03:37 | 
| 合計ジャッジ時間 | 4,413 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge3 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 1 | 
| other | AC * 4 RE * 1 TLE * 1 -- * 13 | 
ソースコード
n=int(input())
a=list(map(int,input().split()))
#ギャグ
mod=10**9+7
if max(a)>3:
    print(mod)
    exit()
ans=1
for i in a:
    sub=1
    for j in range(i):
        sub*=(j+1)
    ans*=(i**sub)
print(mod%ans)