Copy Constructor

A copy constructor is a constructor that takes exactly one argument, which is an object of the class.

It's sole purpose is to initialize a new object as an exact copy of an existing object

Typically, the argument to the copy constructor is a constant reference.

There are two ways to "call" the copy constructor:

  1. class_name  new_object_name ( existing_object_name );

  2. class_name  new_object_name  =  existing_object_name;