[Solved]B3 10 Points Class Name F Public Name Private String Namel Cs Li Weakptrname Wptr Share Pt Q37108028

B.3-10 Points class Name f public: Name() private: string namel “CS li weak_ptrName wPtr; share-ptr<Name> sPtr(nullptr); void func) unique_ptr<Name» obj make_unique<Name> ; // #1 Insert Code int main) ( // #2 Insert Code return 0; (#1 Insert Code]: write code to keep the object which obj owns alive outside of the scope of func and wPtr reference obj (#2 Insert Code): Write code to test if wPtr is dangling. Is it dangling or not? Show transcribed image text B.3-10 Points class Name f public: Name() private: string namel “CS li weak_ptrName wPtr; share-ptr sPtr(nullptr); void func) unique_ptr
Expert Answer
Answer to B.3-10 Points class Name f public: Name() private: string namel “CS li weak_ptrName wPtr; share-ptr sPtr(nullptr); void … . . .
OR

