結果
問題 | No.933 おまわりさんこいつです |
ユーザー | GrayCoder |
提出日時 | 2019-11-29 22:22:09 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 436 bytes |
コンパイル時間 | 88 ms |
コンパイル使用メモリ | 12,800 KB |
実行使用メモリ | 19,700 KB |
最終ジャッジ日時 | 2024-05-01 00:34:19 |
合計ジャッジ時間 | 4,974 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 30 ms
17,564 KB |
testcase_01 | AC | 31 ms
10,624 KB |
testcase_02 | AC | 32 ms
10,752 KB |
testcase_03 | AC | 31 ms
10,752 KB |
testcase_04 | AC | 30 ms
10,752 KB |
testcase_05 | AC | 30 ms
10,752 KB |
testcase_06 | AC | 31 ms
10,752 KB |
testcase_07 | AC | 30 ms
10,752 KB |
testcase_08 | AC | 31 ms
10,624 KB |
testcase_09 | AC | 30 ms
10,752 KB |
testcase_10 | AC | 30 ms
10,752 KB |
testcase_11 | AC | 31 ms
10,624 KB |
testcase_12 | AC | 32 ms
10,880 KB |
testcase_13 | AC | 81 ms
10,752 KB |
testcase_14 | AC | 134 ms
11,008 KB |
testcase_15 | AC | 512 ms
11,392 KB |
testcase_16 | TLE | - |
testcase_17 | -- | - |
testcase_18 | -- | - |
testcase_19 | -- | - |
testcase_20 | -- | - |
testcase_21 | -- | - |
testcase_22 | -- | - |
testcase_23 | -- | - |
testcase_24 | -- | - |
ソースコード
from functools import reduce from operator import mul from sys import stdin def main(): input = lambda: stdin.readline()[:-1] N = int(input()) P = map(int, input().split()) k = reduce(mul, P) ans, d = 0, 1 while 1: while d > 0: d, m = divmod(k, 10) ans += m k = d if ans < 10: break d, k = 1, ans ans = 0 print(ans) main()