Java

Java Clone Example

Java Code:

Output:




The clone() method saves the extra processing task for creating the exact copy of an object.

Leave a Comment