[LeetCode C++实现]225. Implement Stack using Queues
225. Implement Stack using Queues这里使用队列实现stack,使用c++ stl中的deque.
class MyStack {
public:
/** Initialize your data structure here. */
MyStack() {
}
/** Push element x onto stack. */
void push(int x) {
stack.push_back(x);
}
/** Removes the element on top of the stack and returns that element. */......