結果

問題 No.933 おまわりさんこいつです
ユーザー 双六双六
提出日時 2020-07-27 22:56:39
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
RE  
実行時間 -
コード長 420 bytes
コンパイル時間 941 ms
コンパイル使用メモリ 10,636 KB
実行使用メモリ 27,760 KB
最終ジャッジ日時 2023-09-11 06:05:43
合計ジャッジ時間 6,192 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 19 ms
27,760 KB
testcase_01 AC 18 ms
8,448 KB
testcase_02 AC 19 ms
8,548 KB
testcase_03 AC 18 ms
8,456 KB
testcase_04 AC 18 ms
8,460 KB
testcase_05 AC 19 ms
8,452 KB
testcase_06 AC 19 ms
8,612 KB
testcase_07 AC 19 ms
8,416 KB
testcase_08 AC 19 ms
8,432 KB
testcase_09 AC 19 ms
8,500 KB
testcase_10 AC 19 ms
8,432 KB
testcase_11 AC 19 ms
8,600 KB
testcase_12 AC 19 ms
8,556 KB
testcase_13 RE -
testcase_14 RE -
testcase_15 RE -
testcase_16 RE -
testcase_17 AC 47 ms
15,724 KB
testcase_18 AC 18 ms
8,428 KB
testcase_19 AC 123 ms
17,812 KB
testcase_20 RE -
testcase_21 AC 19 ms
8,528 KB
testcase_22 AC 19 ms
8,428 KB
testcase_23 TLE -
testcase_24 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys; input = sys.stdin.buffer.readline
sys.setrecursionlimit(10**7)
from collections import defaultdict
con = 10 ** 9 + 7; INF = float("inf")

def getlist():
	return list(map(int, input().split()))

#処理内容
def main():
	N = int(input())
	P = getlist()
	v = 1
	for i in P:
		v *= i

	while True:
		if v <= 9:
			print(v)
			return

		v = sum(list(map(int, list(str(v)))))


if __name__ == '__main__':
	main()
0