Multiple ChoiceBeginner 45s
Copy-and-swap idiom purpose
What does the copy-and-swap idiom primarily provide for an assignment operator?
Options
- 1Faster copies via a memcpy of the temporary storage
- 2Elimination of the destructor since swap owns resources
- 3Strong exception safety and self-assignment safety
- 4Automatic move assignment deduced for by-value parameters
Think you can answer under pressure?
Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.