I saw a late answer, and that answer did not add anything that previous answers had not already said. If the question had no answer, it would be somewhat useful, but now it doesn't add anything.
The question as this one: What is the difference between cloning the object with .clone() method and = sign?
Is that a reason to downvote or flag?
In case the link gets changed, it was like this:
Question:
I am really confused about what is the difference between .clone() method or simply putting the = sign between objects while trying to clone it.
Old answer:
The = sign is the assignment operator in java. Having a = b means "I assign to the variable a the value of variable b. If b is an object, then a = b makes a point to the object that b is pointing to. It does not copy the object, nor clone it.
If you want to clone an object you either have to do it by hand (ugly), or have to make the class that has to be clonable to implement Clonable then call clone().
The advantage on clone() over the "ugly" way is that with clone() it's the developer of the class to be cloned that defines how cloning has to be done in order to ensure that the copy is a legit and working copy.
New answer:
'=' creates a new reference to the same object. 'clone()' creates a new physical object with the same attributes as the earlier one