Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
34799 swzzzz 【S】T1 C++ 通过 100 181 MS 4184 KB 496 2024-11-14 16:48:22

Tests(10/10):


#include<bits/stdc++.h> using namespace std; #define N 1000006 int n; int a[N]; int main(){ //freopen("reverse.in","r",stdin); //freopen("reverse.out","w",stdout); ios::sync_with_stdio(0); cin>>n; int num; if(n%2){ cin>>num; a[(1+n)/2]=num; } for(int i=n/2;i>=1;i--){ cin>>num; a[n-i+1]=num; cin>>num; a[i]=num; } for(int i=1;i<=n;i++) cout<<a[i]<<' '; cout<<endl; return 0; }


测评信息: