Skip to content

Instantly share code, notes, and snippets.

@sealddr
Last active Oct 7, 2017
Embed
What would you like to do?
#include <iostream>
#include <queue>
using namespace std;
int main(void){
// Here your code !
queue<int> q;
int n=10;
for(int i=0; i<n; i++){
std::cout << "enqueue " << i << std::endl;
q.push(i);
}
for(int i=0; i<n; i++){
std::cout << "dequeue " << q.front() << std::endl;
q.pop();
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment