Senior Java Interview: Bug Fix in a Generic Repository

Understanding wildcard variance in Java generics — and why you can never have both safe reads and safe writes at once