Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
131977 毛靖平 22数列变换III C++ Wrong Answer 1 MS 268 KB 398 2025-10-02 15:29:14

Tests(0/2):


Code:

#include <bits/stdc++.h> using namespace std; int a[105]; int n; void move(int idx){ int tp=a[idx]; for(int i=idx;i<=n;i++){ a[i]=a[i+1]; } a[n]=tp; } int main(){ int n,max=0,k,t; cin>>n; for(int i=1;i<=n;i++){ cin>>a[i]; } cin>>k; while(k--){ cin>>t; move(t); } for(int i=1;i<=n;i++){ cout<<a[i]<<" "; } return 0; }


Run Info:

------Input------
10 1 2 3 4 5 6 7 8 9 10 4 4 3 2 5
------Answer-----
1 5 6 7 9 10 4 3 2 8
------Your output-----
1 2 3 4 5 6 7 8 9 10