Ensure transients are deleted to avoid unbounded memory growth; member vars get underscore.
A more C++11-ish way of iterating.
Commentary.