結果

問題 No.1013 〇マス進む
ユーザー otamay6otamay6
提出日時 2019-11-08 14:34:23
言語 C++14
(gcc 13.2.0 + boost 1.83.0)
結果
TLE  
(最新)
AC  
(最初)
実行時間 -
コード長 543 bytes
コンパイル時間 1,626 ms
コンパイル使用メモリ 167,232 KB
実行使用メモリ 5,552 KB
最終ジャッジ日時 2023-10-13 07:09:44
合計ジャッジ時間 18,462 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 AC 1 ms
4,348 KB
testcase_03 AC 6 ms
4,348 KB
testcase_04 AC 4 ms
4,352 KB
testcase_05 AC 7 ms
4,352 KB
testcase_06 AC 2 ms
4,352 KB
testcase_07 AC 9 ms
4,356 KB
testcase_08 AC 8 ms
4,352 KB
testcase_09 AC 3 ms
4,356 KB
testcase_10 AC 3 ms
4,348 KB
testcase_11 AC 6 ms
4,352 KB
testcase_12 AC 3 ms
4,356 KB
testcase_13 AC 50 ms
4,352 KB
testcase_14 AC 861 ms
4,348 KB
testcase_15 AC 693 ms
4,836 KB
testcase_16 AC 881 ms
4,640 KB
testcase_17 AC 397 ms
4,348 KB
testcase_18 AC 926 ms
4,492 KB
testcase_19 AC 107 ms
4,352 KB
testcase_20 AC 392 ms
5,280 KB
testcase_21 AC 653 ms
4,352 KB
testcase_22 AC 468 ms
4,376 KB
testcase_23 AC 119 ms
4,348 KB
testcase_24 AC 1,263 ms
5,552 KB
testcase_25 AC 990 ms
5,156 KB
testcase_26 AC 292 ms
4,368 KB
testcase_27 AC 237 ms
4,376 KB
testcase_28 AC 51 ms
4,368 KB
testcase_29 AC 434 ms
5,108 KB
testcase_30 AC 541 ms
4,372 KB
testcase_31 AC 920 ms
4,368 KB
testcase_32 AC 527 ms
4,372 KB
testcase_33 TLE -
testcase_34 -- -
testcase_35 -- -
testcase_36 -- -
testcase_37 -- -
testcase_38 -- -
testcase_39 -- -
testcase_40 -- -
testcase_41 -- -
testcase_42 -- -
testcase_43 -- -
testcase_44 -- -
testcase_45 -- -
testcase_46 -- -
testcase_47 -- -
testcase_48 -- -
testcase_49 -- -
testcase_50 -- -
testcase_51 -- -
testcase_52 -- -
testcase_53 -- -
testcase_54 -- -
testcase_55 -- -
testcase_56 -- -
testcase_57 -- -
testcase_58 -- -
testcase_59 -- -
testcase_60 -- -
testcase_61 -- -
testcase_62 -- -
testcase_63 -- -
testcase_64 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<bits/stdc++.h>
#define REP(i,n) for(int i=0,i##_len=(n);i<i##_len;++i)
#define rep(i,a,b) for(int i=int(a);i<int(b);++i)
#define All(x) (x).begin(),(x).end()
using namespace std;
typedef long long ll;

vector<ll> Gutyoku(ll N,ll K,const vector<ll> p){
    vector<ll> ret(N);
    REP(i,N){
        ll tmp=i;
        REP(j,K) tmp+=p[tmp%N];
        ret[i]=tmp+1;
    }
    return ret;
}

int main(){
    ll N,K;cin>>N>>K;
    vector<ll> p(N);
    REP(i,N) cin>>p[i];
    vector<ll> ans=Gutyoku(N,K,p);
    REP(i,N) cout<<ans[i]<<endl;
}
0