結果

問題 No.16 累乗の加算
ユーザー tookunn_1213tookunn_1213
提出日時 2015-08-20 09:50:17
言語 Python2
(2.7.18)
結果
MLE  
実行時間 -
コード長 172 bytes
コンパイル時間 169 ms
コンパイル使用メモリ 6,664 KB
実行使用メモリ 813,692 KB
最終ジャッジ日時 2023-09-25 13:45:57
合計ジャッジ時間 2,690 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 11 ms
5,828 KB
testcase_01 AC 11 ms
5,804 KB
testcase_02 MLE -
testcase_03 -- -
testcase_04 -- -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

x,N = map(int,raw_input().split())
a = map(int,raw_input().split())
ans = 0
for i in range(N):
	xx = 1
	for j in range(a[i]):
		xx *= x
	ans += xx
	ans %= 1000003
print ans
0