Answer Posted / sagarson
Copy constructors are called in following cases:
a) when a function returns an object of that class by value
b) when the object of that class is passed by value as an
argument to a function
c) when you construct an object based on another object of
the same class
d) When compiler generates a temporary object
Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
What is code reusability in c++?
In int main(int argc, char *argv[]) what is argv[0] a) The first argument passed into the program b) The program name c) You can't define main like that
Write about c++ storage classes?
Where do I find the current c or c++ standard documents?
What is a driver program?
What is the best book for c++ beginners?
Can you pass an array to a function in c++?
How do you clear a map in c++?
How do c++ struct differs from the c++ class?
What is c++ manipulator?
What is c++ array?
Is it possible to have a recursive inline function in c++?
What is the use of "new" operator?
What is a storage class? Mention the storage classes in c++.
What is the maximum combined length of command line arguments including the space between adjacent arguments?