monotonic stack (stack maintaining sorted order) maintains elements in sorted order (increasing or decreasing), popping elements that violate the order when pushing new ones. You use it when finding the next greater or smaller element for each position. It processes elements once while maintaining relationships, achieving for problems that seem to require .
You'll see this in histogram and temperature problems. If you can explain these concepts in your own words, you'll solve related problems faster under interview pressure.