What changed in Java 2 (1.2)
2 changes across 2 questions — each with the behaviour it replaced, because “and how did it work before?” is the follow-up.
How does HashMap work internally?
HashMap arrives in the collections framework, unsynchronized, permitting one null key and any number of null values.
Before: Hashtable was the only choice: every method synchronized whether you needed it or not, and it throws NullPointerException on a null key or value.
When would you use LinkedList instead of ArrayList?
ArrayList and LinkedList arrive with the collections framework, unsynchronized so you pay for locking only when you ask for it.
Before: Vector was the only growable list, and every method was synchronized whether or not the list was shared.