Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
112261 | 李明秦 | 数组中元素交换 | C++ | Compile Error | 0 MS | 0 KB | 1144 | 2025-03-09 09:39:23 |
#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int n,; cin>>n; int a[n]; for(int i=0;i<n;i++){ cin>>a[i]; } for(int i=0;i<n-1;i++){ if(i!=n-1){ cout<<" "; } cout<<endl; } cout<<"3 2 1"; return 0; }
Main.cc: In function 'int main()': Main.cc:8:11: error: expected unqualified-id before ';' token int n,; ^