Problem 1381 · Medium
Store a lazy add beside each stack slot so an increment touches one entry, and pass it down on pop.
Open the interactive visualisation