ขนาดวิดีโอ: 1280 X 720853 X 480640 X 360
แสดงแผงควบคุมโปรแกรมเล่น
เล่นอัตโนมัติ
เล่นใหม่
8:37 the program on the right should use in the deconstructor code "delete [] data_", and not "delete data_" just the way it was done on the program in the left to be able to delete the whole dynamically created array.
Thank you so much sir!
thank you NPTEL team
thanks!!
To invoke a destructor explicitly need to call s.~Stack(), but not Stack::~Stack(&s).
8:37 the program on the right should use in the deconstructor code "delete [] data_", and not "delete data_" just the way it was done on the program in the left to be able to delete the whole dynamically created array.
Thank you so much sir!
thank you NPTEL team
thanks!!
To invoke a destructor explicitly need to call s.~Stack(), but not Stack::~Stack(&s).