mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-12 19:01:47 +08:00
批量更新数据
This commit is contained in:
@@ -14,15 +14,15 @@
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>示例 1:</strong></p>
|
||||
<p><strong>示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>
|
||||
["MinStack","push","push","push","getMin","pop","top","getMin"]
|
||||
[[],[-2],[2],[-3],[],[],[],[]]
|
||||
[[],[-2],[0],[-3],[],[],[],[]]
|
||||
|
||||
<strong>输出:</strong>
|
||||
[null,null,null,null,-3,null,2,-2]
|
||||
[null,null,null,null,-3,null,0,-2]
|
||||
|
||||
<strong>解释:</strong>
|
||||
MinStack minStack = new MinStack();
|
||||
@@ -31,7 +31,7 @@ minStack.push(2);
|
||||
minStack.push(-3);
|
||||
minStack.getMin(); --> 返回 -3.
|
||||
minStack.pop();
|
||||
minStack.top(); --> 返回 2.
|
||||
minStack.top(); --> 返回 0.
|
||||
minStack.getMin(); --> 返回 -2.
|
||||
</pre>
|
||||
|
||||
|
Reference in New Issue
Block a user