結果
問題 | No.933 おまわりさんこいつです |
ユーザー |
![]() |
提出日時 | 2019-12-01 11:59:37 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
RE
(最新)
AC
(最初)
|
実行時間 | - |
コード長 | 382 bytes |
コンパイル時間 | 101 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 22,096 KB |
最終ジャッジ日時 | 2024-11-21 04:33:30 |
合計ジャッジ時間 | 3,251 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 RE * 5 |
ソースコード
def digit(n): if n==0: return 0 q=str(n) tmp=0 for i in range(len(q)): tmp+=int(q[i]) if tmp%9!=0: tmp%=9 else: tmp=9 return tmp n=int(input()) p=list(map(int,input().split())) ct=1 for i in range(n): if p[i]%9!=0: ct*=(p[i]%9) elif p[i]==0: ct*=0 else: ct*=9 ans=digit(ct) print(ans)