What is a dangling reference?
- A A reference to an object that has been destroyed
- B A reference that was never initialised
- C A null reference
- D A reference to a const object
Answer
A reference to an object that has been destroyed
Returning a reference to a local variable, or holding a reference to a vector element after reallocation, both produce dangling references.





