Back to Question
Implement a Min Stack
Question Explain
Design a stack that supports push, pop, top, and retrieving the minimum element in $O(1)$ time. This requires using auxiliary storage with the main stack.
Start Trying This Question Simulation
Click "Start Speaking" and answer the question naturally.