# Little Y's Segment Tree: Process Queries by Right Endpoint ## An interval stack is a suffix of a prefix stack Position $i$ survives after processing through $r$ exactly when no $j$ with $i