Back to Question

Min Stack

Question Explain

Design a stack that supports push, pop, top, and retrieving the minimum element in $O(1)$ time.

Start Trying This Question Simulation

Click "Start Speaking" and answer the question naturally.