/*
卡片游戏
*/
#include<cstdio>
#include<queue>
using namespace std;
queue<int> q;
main()
{
int n;
scanf("%d", &n);
for(int i=0; i<n; i++)
q.push(i+1);
while(!q.empty())
{
printf("%d ", q.front());
q.pop();
q.push(q.front());
q.pop();
}
return 0;
}
卡片游戏3-STL
最新推荐文章于 2020-05-18 18:13:00 发布