結果
問題 |
No.500 階乗電卓
|
ユーザー |
|
提出日時 | 2021-04-10 14:59:05 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 43 ms / 2,000 ms |
コード長 | 284 bytes |
コンパイル時間 | 337 ms |
コンパイル使用メモリ | 82,724 KB |
実行使用メモリ | 52,352 KB |
最終ジャッジ日時 | 2024-06-26 04:20:27 |
合計ジャッジ時間 | 2,016 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 20 |
ソースコード
n = int(input()) ans = [] now = 1 check = "0"*12 for i in range(1000): now *= max(1,i) ans.append(now) if len(str(now)) > 12 and str(now)[::-1][:12][::-1] == check: break #print(len(ans)) if n >= 50: print(check) else: print(str(ans[n])[::-1][:12][::-1])