Skip to content

Glossary: Coding Interviews in Rust

Stack

A last-in, first-out list, here a plain `Vec` using `push`, `pop` and `last`. It fits "most recent", "undo" and "matching" problems like Alex's cancelling scans.

Where the book teaches it

Related terms

Monotonic stack