結果

問題 No.16 累乗の加算
ユーザー mmmpppmmmppp
提出日時 2017-02-28 00:57:03
言語 Ruby
(3.3.0)
結果
TLE  
実行時間 -
コード長 89 bytes
コンパイル時間 59 ms
コンパイル使用メモリ 11,544 KB
実行使用メモリ 19,648 KB
最終ジャッジ日時 2023-09-02 13:42:45
合計ジャッジ時間 6,840 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 82 ms
15,244 KB
testcase_01 AC 85 ms
15,148 KB
testcase_02 TLE -
testcase_03 -- -
testcase_04 -- -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.rb:2: warning: assigned but unused variable - n
Syntax OK

ソースコード

diff #

d=1000003
x,n,*a=$<.read.split.map &:to_i
s=0;a.map{|e|t=1;e.times{t=(t*x)%d};s+=t};p s%d
0