You are viewing a single comment's thread. Return to all comments →
Wouldn't it be better to explicitly deallocate the objects at the end, i.e. through
for(int i=0;i<n;i++) { delete per[i]; per[i] = 0; }
? Not doing it might not be troublesome in this case, but perhaps doing it would encourage better practice. Do you agree?
Seems like cookies are disabled on this browser, please enable them to open this website
Virtual Functions
You are viewing a single comment's thread. Return to all comments →
Wouldn't it be better to explicitly deallocate the objects at the end, i.e. through
? Not doing it might not be troublesome in this case, but perhaps doing it would encourage better practice. Do you agree?