皓仔的逆序输出
2026-05-31 21:58:20
发布于:浙江
9阅读
0回复
0点赞
这题可以用函数写
具体代码长这样:
#define DEBUG
#include<bits/stdc++.h>
using namespace std;
int a[10005];
void f(){
for(int i=4;i>=1;i--){
cout<<a[i]<<" ";
}
}
int main(){
ios::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
for(int i=1;i<=4;i++){
cin>>a[i];
}
f();
}
这里空空如也


有帮助,赞一个