0
I want to have clear explanations about features in equal() method.
I want mainly to know why to use Null, hashcode.
1 Odpowiedź
+ 1
The equals() method is used to check objects content and you can go through following links to get clear understanding..
https://www.google.com/amp/s/www.geeksforgeeks.org/difference-equals-method-java/amp/
https://stackoverflow.com/questions/3563847/what-is-the-use-of-hashcode-in-java
https://www.google.com/amp/s/www.geeksforgeeks.org/internal-working-of-hashmap-java/amp/
https://stackoverflow.com/questions/21535029/what-must-be-hashcode-of-null-objects-in-java#:~:text=When%20p2%20is%20null%20%2C%20invoking,()%20as%20in%20this%20case.