Stack and count