Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <set>
- #include <queue>
- #include <vector>
- #include <queue>
- #include <stack>
- using namespace std;
- int main() {
- stack<int> st;
- st.push(1);
- st.push(2);
- st.push(3);
- st.push(4);
- while(!st.empty()) {
- cout << st.top() << " ";
- st.pop();
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment