What is the difference between a copy constructor and an
overloaded assignment operator?
Answer Posted / vsinghal
In case of copy constructor when the object goes out of
scope its destructor will be called while in case of
assignment operator no destructor will be called.
| Is This Answer Correct ? | 12 Yes | 14 No |
Post New Answer View All Answers
What is the need of a destructor? Explain with the help of an example.
Write my own zero-argument manipulator that should work same as hex?
What is static function? Explain with an example
what is a reference variable in C++?
What c++ library is string in?
What is the operator in c++?
Define a constructor?
What is static class data?
Should a constructor be public or private?
Can we overload operator in c++?
What is an undefined reference/unresolved external symbol error and how do I fix it?
How to tokenize a string in c++?
What is a wchar_t in c++?
What are the effects after calling the delete this operator ?
List the advantages of inheritance.