Q. Which of the following is the correct way to define a copy assignment operator in C++?
β
Correct Answer: (A)
MyClass& operator=(const MyClass& other) { }
Explanation: The correct way to define a copy assignment operator is 'MyClass& operator=(const MyClass& other) { }'.