結果

問題 No.933 おまわりさんこいつです
ユーザー pekempeypekempey
提出日時 2019-11-29 21:45:56
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 115 ms / 2,000 ms
コード長 158 bytes
コンパイル時間 979 ms
コンパイル使用メモリ 87,016 KB
実行使用メモリ 94,020 KB
最終ジャッジ日時 2023-08-13 05:08:59
合計ジャッジ時間 4,322 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 75 ms
71,360 KB
testcase_01 AC 74 ms
71,224 KB
testcase_02 AC 74 ms
71,444 KB
testcase_03 AC 73 ms
71,000 KB
testcase_04 AC 74 ms
71,284 KB
testcase_05 AC 73 ms
71,372 KB
testcase_06 AC 74 ms
71,292 KB
testcase_07 AC 75 ms
71,312 KB
testcase_08 AC 74 ms
71,008 KB
testcase_09 AC 73 ms
71,168 KB
testcase_10 AC 74 ms
71,372 KB
testcase_11 AC 74 ms
71,004 KB
testcase_12 AC 74 ms
71,088 KB
testcase_13 AC 115 ms
76,268 KB
testcase_14 AC 77 ms
76,312 KB
testcase_15 AC 80 ms
76,256 KB
testcase_16 AC 85 ms
79,492 KB
testcase_17 AC 89 ms
86,000 KB
testcase_18 AC 73 ms
71,164 KB
testcase_19 AC 94 ms
89,376 KB
testcase_20 AC 94 ms
89,012 KB
testcase_21 AC 75 ms
71,008 KB
testcase_22 AC 75 ms
71,216 KB
testcase_23 AC 107 ms
94,020 KB
testcase_24 AC 106 ms
93,740 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
P = list(map(int, input().split()))
if 0 in P:
  print(0)
else:
  ans = 1
  for x in P:
    ans *= x
    ans %= 9
  print((ans - 1) % 9 + 1)
0