In Java, there is no operator to create a copy of an object . Unlike C++, in Java, if we use the assignment operator then it will create a copy of the reference variable and not the object.
In Java, there is no operator to create a copy of an object . Unlike C++, in Java, if we use the assignment operator then it will create a copy of the reference variable and not the object.