#include "course.h" using namespace std; int main() { Course c; //call the default constructor //non-default constructor is called Course c1 ("CS261", 3, "Instructor"); c = c1; //c.operator=(c1); c.display(); c1.display(); //delete [] c1.roster Course c2 = c1; return 0; } //destrucof of c1 and c are called // //before deep copy // print c // $1 = { // name = "CS261", // roster = 0x4182c8, // enroll = 3, // ins = "Instructor" // } // >>> print c1 // $2 = { // name = "CS261", // roster = 0x4182c8, // enroll = 3, // ins = "Instructor" // } // //after deep copy: // p c // $1 = { // name = "CS261", // roster = 0x418338, // enroll = 3, // ins = "Instructor" // } // >>> p c1 // $2 = { // name = "CS261", // roster = 0x4182c8, // enroll = 3, // ins = "Instructor" // }