Solved

Which of the Following Statements About a Unique_ptr Object Is

Question 19

Multiple Choice

Which of the following statements about a unique_ptr object is true?


A) A unique_ptr is a "smart pointer" for managing dynamically allocated memory.
B) When a unique_ptr goes out of scope, its destructor automatically returns the managed memory to the free store.
C) You must explicitly delete the memory that's managed by a unique_ptr before the object goes out of scope.
D) All of the above.

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions

Unlock this Answer For Free Now!

View this answer and more for free by performing one of the following actions

qr-code

Scan the QR code to install the App and get 2 free unlocks

upload documents

Unlock quizzes for free by uploading documents