05 January 2017
原文: O(1) 时间取得栈内最小数据

入栈顺序:

5 7 3 8 2 1
栈(s)   辅助栈(x)
 1        1
 2        2
 8        3
 3        3
 7        5
 5        5
push(num)
    if s.size == 0
        s.push(num)
        x.push(num)
    else
        curMinNum = x.top()

        if num < curMinNum
            s.push(num)
            x.push(num)
        else
            s.push(num)
            x.push(curMinNum)


pop()
    curNum = s.pop()
    minNum = x.pop()

    return [ curNum, minNum ]