Implement the following operations of a queue using stacks.push(x) -- Push element x to the back of queue.pop() -- Removes the element from in front o...
分类:
其他好文 时间:
2015-08-02 15:02:17
阅读次数:
82
Design a stack that supports push, pop, top, and retrieving the minimum element in constant time.push(x) -- Push element x onto stack.pop() -- Removes...
分类:
其他好文 时间:
2015-08-01 23:17:36
阅读次数:
108
题目Implement the following operations of a queue using stacks.push(x) – Push element x to the back of queue.
pop() – Removes the element from in front of queue.
peek() – Get the front element.
empty(...
分类:
其他好文 时间:
2015-08-01 10:08:20
阅读次数:
120
Implement the following operations of a queue using stacks.
push(x) -- Push element x to the back of queue.pop() -- Removes the element from in front of queue.peek() -- Get the front element.empty(...
分类:
其他好文 时间:
2015-07-31 18:29:47
阅读次数:
93
Implement the following operations of a stack using queues.
push(x) -- Push element x onto stack.pop() -- Removes the element on top of the stack.top() -- Get the top element.empty() -- Return whet...
分类:
其他好文 时间:
2015-07-31 18:23:24
阅读次数:
77
Implement the following operations of a queue using stacks.push(x) -- Push element x to the back of queue.pop() -- Removes the element from in front o...
分类:
其他好文 时间:
2015-07-30 22:43:42
阅读次数:
113
Implement the following operations of a stack using queues.push(x) -- Push element x onto stack.pop() -- Removes the element on top of the stack.top()...
分类:
其他好文 时间:
2015-07-30 21:06:04
阅读次数:
113
Implement the following operations of a stack using queues.push(x) -- Push element x onto stack.pop() -- Removes the element on top of the stack.top() -- Get the top element.empty() -- Return whether...
分类:
其他好文 时间:
2015-07-27 19:07:07
阅读次数:
87
Implement the following operations of a stack using queues.push(x) -- Push element x onto stack.pop() -- Removes the element on top of the stack.top()...
分类:
其他好文 时间:
2015-07-23 13:42:34
阅读次数:
106
Implement the following operations of a queue using stacks.push(x) -- Push element x to the back of queue.pop() -- Removes the element from in front of queue.peek() -- Get the front element.empty() --...
分类:
其他好文 时间:
2015-07-21 17:22:00
阅读次数:
109