About This Pattern
Master the Stack pattern by practicing these problems organized by difficulty.Focus on the Key Signals - these are the indicators that tell you when to use this pattern.
Easy (1)
Valid Parentheses
Determine if string of brackets is valid with proper opening and closing.
Key Signals:
Matching pairsLast opened first closedLIFO structure
Medium (2)
Evaluate Reverse Polish Notation
Evaluate the value of an arithmetic expression in Reverse Polish Notation.
Key Signals:
Postfix notationOperands on stackOperators pop and push
Basic Calculator II
Implement a basic calculator to evaluate a string expression with +, -, *, /.
Key Signals:
Expression evaluationOperator precedenceStack for operations