Exploration 45 introduced exceptions, which you have used in a number of programs since then. Dynamic memory presents a new wrinkle with regard to exceptions, and you must be that much more careful when handling them, in order to do so safely and properly in the face of dynamic memory management. In particular, you have to watch for memory leaks and similar problems.
Careless use of dynamic memory and exceptions can result in memory leaks—that is, memory that a program allocates but fails to free. In modern desktop operating systems, when an application terminates, the operating system reclaims all ...