結果
問題 |
No.500 階乗電卓
|
ユーザー |
|
提出日時 | 2017-04-09 16:28:47 |
言語 | Python2 (2.7.18) |
結果 |
AC
|
実行時間 | 12 ms / 2,000 ms |
コード長 | 182 bytes |
コンパイル時間 | 161 ms |
コンパイル使用メモリ | 6,912 KB |
実行使用メモリ | 6,528 KB |
最終ジャッジ日時 | 2024-06-25 02:58:34 |
合計ジャッジ時間 | 1,123 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 20 |
ソースコード
#yuki_500 import math import sys n=int(raw_input()) if n>100: print '0'*12 sys.exit() res=math.factorial(n) if res<10**12: print res else: res2=res%10**12 print "%012d" % res2