@@ -0,0 +1,824 @@
+import java.util.Stack;%0A%0Apublic class MinStack %7B%0A%0A    private int min;%0A    private Stack%3CInteger%3E stack;%0A%0A    /** initialize your data structure here. */%0A    public MinStack() %7B%0A%0A        min = Integer.MAX_VALUE;%0A        stack = new Stack%3CInteger%3E();%0A%0A    %7D%0A%0A    public void push(int x) %7B%0A%0A        if (x %3C= min) %7B%0A            stack.push(min);%0A            min = x;%0A        %7D%0A%0A        stack.push(x);%0A%0A    %7D%0A%0A    public void pop() %7B%0A%0A        if (stack.pop() == min) %7B%0A            min = stack.pop();%0A        %7D%0A%0A    %7D%0A%0A    public int top() %7B%0A        return stack.peek();%0A    %7D%0A%0A    public int getMin() %7B%0A        return min;%0A    %7D%0A%0A%7D%0A%0A/**%0A * Your MinStack object will be instantiated and called as such:%0A * MinStack obj = new MinStack();%0A * obj.push(x);%0A * obj.pop();%0A * int param_3 = obj.top();%0A * int param_4 = obj.getMin();%0A */%0A

Create : 155 Min Stack