Build Stacks and Queues
MinStack and monotonic stacks
Challenge 2 of Linear Structures & BitsBeginner~55 minFree
Master stacks and queues by building them from scratch and applying them to real problems: LIFO and FIFO containers, balanced-bracket parsing, a queue made of two stacks, an O(1) MinStack, and a monotonic stack for next-greater-element.