DIY: Min Stack
Solve the interview question "Min Stack" in this lesson.
Problem statement
You have to implement the MinStack
class, which has a min()
function. Whenever min()
is called, the minimum value of the stack is returned in O(1) ...
Solve the interview question "Min Stack" in this lesson.
You have to implement the MinStack
class, which has a min()
function. Whenever min()
is called, the minimum value of the stack is returned in O(1) ...