Skip to content
Related Articles

Related Articles

Improve Article
C++ | Constructors | Question 2
  • Difficulty Level : Basic
  • Last Updated : 03 Mar, 2013

When a copy constructor may be called?
(A) When an object of the class is returned by value.
(B) When an object of the class is passed (to a function) by value as an argument.
(C) When an object is constructed based on another object of the same class
(D) When compiler generates a temporary object.
(E) All of the above

Answer: (E)

Explanation: See When is copy constructor called?

Quiz of this Question

Want to learn from the best curated videos and practice problems, check out the C Foundation Course for Basic to Advanced C.
My Personal Notes arrow_drop_up
Recommended Articles
Page :