What's the difference between .equals and ==?
.equals
==
== cannot be applied to String
String
They do the exact same thing
== is a wrapper of .equals() and checks for nulls Source:
.equals()
== won't work on objects