#include <queue> #include <iostream> #include <cstdio> #include <cctype> using namespace std; typedef long long ll; queue < ll > q; inline ll read () { ll x=0,f=1; char ch=getchar(); while(!isdigit(ch)) { if(ch=='-') f=-1; ch=getchar(); } while(isdigit(ch)) { x=(x<<1)+(x<<3)+(ch^48); ch=getchar(); } return x*f; } int n; signed main() { n=read(); for(register int i=1; i<=n; i++) q.push(read()); while(!q.empty()){ cout<<q.front()<<' '; q.pop(); } return 0; //q.empty() 判断队列是否是空的 //q.clear() 清空队列 //q.push(x) 把x放到队尾 //q.front() q的第一个元素 //q.pop() q的第一个元素出队 //q.size() q的元素个数 }