if I had a Person
object and did final Person p = new Person("me");
it means I can’t reassignp
to point to another Person
object. I can still do p.setFirstName("you");
What confuses the situation is that
final int PI = 3.14;
final String greeting = "Hello World!";
Containers or objects with mutator methods that can alter the internal state of the object are not const
just the reference to those objects are final
and can’t be reassigned to reference another object.