def top(self):
        x = self.stack[-1]
        if x > 0:
            return x + self.min
        else:
            return self.min
        
    # @return an integer
dataset/ETHPy150Open kamyu104/LeetCode/Python/min-stack.py/MinStack.top/original