What is the Diffrence between a "assignment operator" and a
"copy constructor"?
Answer Posted / dee
assignment operator copies the values of one object to
another of the same class.It will excute only when the
right side of the variable is object and two sides are not
equal.It does shallow copy
Copy constructor craetes the object if its not existing and
copies the values of another object of the same class and
it does the deep copy.
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
Explain about templates of C++.
What are the important differences between c++ and java?
Can we distribute function templates and class templates in object libraries?
Can manipulators fall in love?
What is the benefit of learning c++?
Is string an object in c++?
What is function overloading in C++?
Can static member variables be private?
What are vtable and vptr?
Incase of a function declaration, what is extern means?
What are static type checking?
What are the restrictions apply to constructors and destructors?
What are the operators in c++?
What are pointers used for c++?
Define pure virtual function?