What is the purpose of using a destructor in c++?
Answers
Answered by
2
destructor is a special member function that is called when the lifetime of an object ends. The purpose of the destructor is to free the resources that the object may have acquired during its lifetime.
Similar questions