結果
問題 | No.933 おまわりさんこいつです |
ユーザー |
👑 |
提出日時 | 2025-03-01 20:37:02 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 1,785 ms / 2,000 ms |
コード長 | 244 bytes |
コンパイル時間 | 260 ms |
コンパイル使用メモリ | 82,740 KB |
実行使用メモリ | 93,516 KB |
最終ジャッジ日時 | 2025-03-01 20:37:09 |
合計ジャッジ時間 | 5,835 ms |
ジャッジサーバーID (参考情報) |
judge6 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 25 |
ソースコード
import sys sys.set_int_max_str_digits(0) N = int(input()) P = list(map(int, input().split())) ans = 1 for p in P: ans *= sum(int(_p) for _p in str(p)) if ans >= 10: while ans >= 10: ans = sum(map(int, str(ans))) print(ans)