class Solution: stack=[] def push(self, node): # write code here self.stack.append(node) def pop(self): # write code here self.stack.pop() def top(self): # write code here return self.stack[-1] def min(self): min=self.stack[0] for s in self.stack: if s<min: min=s return min