Answer these questions about destructors
a) What is a destructor and what must the name of a destructor be?
b) When is a destructor called?
c) What does a destructor actually do?
d) What should a destructor do?
a) A destructor is a member function of a class named ~NameOfClass.
b) A destructor is called automatically at the end of the block when a class object goes out of scope.
c) A destructor actually does whatever the class author has written into the
destructor
d) A destructor should release any resources that the constructor has
allocated, including releasing dynamically allocated memory.
You might also like to view...
The part of the computer responsible for retrieving data and instructions from memory for processing is the __________.
a. hardware b. loader c. central processing unit d. linker e. instruction data fetch unit
Which variable assignment method is useful when you need information from the user to complete the script?
A. Conditional B. Direct assignment C. Prompt D. Positional parameter
The formatting of your resume does not matter as long as all of the important information is included
Indicate whether the statement is true or false
Which permissions would the command chmod 740 give?
A) rwxr - - - - - B. r - xrwxrwx C. rw - r - x - - x D. - w - - w - - w -