boost::scoped_ptr provides exclusive ownership of a dynamically allocated object. It takes ownership at construction, prevents assignment, and deletes the object when the pointer leaves scope. section 10.6
This makes exception paths easier to maintain than manual raw-pointer cleanup. Use boost::shared_ptr when ownership must be shared; modern C++ offers std::unique_ptr for transferable exclusive ownership. section 10.6
Managing Student resources
A try block creates boost::scoped_ptr<Student> objects for Samuel, Virginia, and Eugene. Eugene’s invalid GPA throws; scope-based ownership cleans up already-created objects without explicit delete calls. section 10.6
