What is the difference between '==' and '.equals()' in Java?
'==' compares if two objects have the same values, and '.equals()' compares the objects themselves.
You're close! The key difference is that '==' compares object references, not values.
Can you explain how to use '.equals()' when comparing two objects of a custom class?