Key Point
- Stack Clear 하는 법
Code
#include <iostream>
#include <stack>
using namespace std;
stack<int> s;
int main(){
s.push(1);
s.push(2);
s.push(3);
/*
Stack Clear !
*/
while( !s.empty() )
s.pop();
return 1;
}