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