I tried to search for this but couldn't find an answer easily.
If we have multiple Integer
Java objects corresponding to the same integer value--are they the same in memory?
No, but if you use Integer.valueOf(),
Long.valueOf(),
etc you may get single cached values. Not the same thing.