Java Collections Framework
Lists, Sets, Maps, Queues, the equals/hashCode contract, concurrent collections, and the modern Sequenced Collections API. The single most-asked area in any Java interview.
Framework Overview & Hierarchy
How the framework is organized — Iterable, Collection, Map, the optional-operations contract, and why "Collection" and "Collections" are different things.
List, ArrayList, LinkedList
How ArrayList grows, when (almost never) to pick LinkedList, and the tarpit of Arrays.asList vs List.of vs Collections.unmodifiableList.
Set, HashSet, LinkedHashSet, TreeSet
The three production-grade Set implementations: hash-based, insertion-ordered, and sorted.
Map, HashMap Internals
The single most-asked Java topic. Inside hash(), resize(), treeification, load factor, and the contract for null.
LinkedHashMap & LRU Cache
How LinkedHashMap weaves a doubly-linked list through HashMap, and how that gives you an LRU cache in 5 lines.
TreeMap, NavigableMap, SortedMap
Red-black tree under the hood, log-n everything, and the navigation API senior engineers use to solve interval problems.
equals and hashCode Contract
The contract every Java developer must internalize: five properties of equals, the hashCode invariant, and the inheritance trap.
Comparable vs Comparator
Natural ordering vs external ordering, and the "consistent with equals" trap most senior engineers can name but not explain.
Queue, Deque, ArrayDeque, PriorityQueue
The Queue throw-vs-return method matrix, why ArrayDeque replaces Stack, and the PriorityQueue iterator trap.
Iterator, ListIterator, Iterable, Spliterator
The iteration protocol, modCount and ConcurrentModificationException, and how Spliterator powers parallel streams.
Concurrent Collections — ConcurrentHashMap
How CHM redesigned itself in Java 8, why size() is approximate, and the right way to use computeIfAbsent.
BlockingQueue Family
The producer-consumer toolbox. Which queue each Executors factory uses, why newFixedThreadPool can take down production.
CopyOnWriteArrayList, ConcurrentSkipListMap, ConcurrentLinkedQueue
The lesser-known concurrent toolbox: copy-on-write for read-mostly state, skip list for sorted concurrent access, lock-free queues.
Collections Utility Class
Static helpers and wrappers: unmodifiable vs immutable vs synchronized, and the algorithms most people forget.
Modern Features (Java 9–25)
Factory methods, Stream.toList, Sequenced Collections (Java 21), Records as map keys, virtual-thread implications.