C++20 sections · 1024 units
Open in CourseQuiz: Smart Pointer Choice
Knowledge check
Check Your Understanding
When should you use unique_ptr over shared_ptr?
- A.When you want to copy the pointer freely
- B.When multiple parts of code need to share ownership
- C.When you need to break circular references
- D.When you have clear single ownership and want zero overhead