pre-requirement-
• 57. types of constructor in java - Default...
copy constructor is a constructo which is used to construct an object by copying the stae from another objet of the same class.
java does not provide default copy constructor so we have to write our own copy constructor.
how to write a copy constructor in java:-
declare a constructor which takes object of same type as an input then manually copy each field of object into new instance.