Social Sciences, asked by anand8926, 1 year ago

How to compare two objects in java example?

Answers

Answered by sofiagupta2001
3
Comparing for value equality
To be able to compare two Java objects of the same class the boolean equal method must be overriden and implemented by the class.
The implementor decides which values must be equal to consider two objects to be equal.
Similar questions