#include <iostream>

#include <string>

#include <fstream>

#include <vector>

#include <algorithm>

#include <deque>

#include <stack>

using namespace std;

void test01()

{

    stack<int> s;  

    s.push(1);

    s.push(2);

    s.push(3);

    s.push(4);


 

    while(!s.empty())  

    {

        cout << s.top() << endl;

        s.pop();

    }





 

}

int main()

{

    test01();

    return 0;

    system("pause");


 

}

更多推荐