I constructed a class with one String field. Then I created two objects and I have to compare them using == operator and .equals() too
String
==
.equals()
It looks like equals2 is just calling equals, so it will give the same results.
equals2
equals