stack<int> mystack; //create mystack.push(1); mystack.pop(); // no return value mystack.size(); mystack.empty(); //true
if the underlying container's size is0
,false
otherwise.
mystack.top(); // access the top element
转载于:https://www.cnblogs.com/XingyingLiu/p/5115392.html