Challenge 2: Attempting new T() Inside a Generic Class — Possible Solution ==================================================================== Broken attempt — Pair.java: public class Pair { private T first; private T second; public T createDefault() { T value = new T(); // attempting to instantiate the type parameter return value; } } Representative compile error: Pair.java:5: error: unexpected type T value = new T(); ^ required: class found: type parameter T where T is a type-variable: T extends Object declared in class Pair Explanation: By the time Pair's bytecode exists, T has been erased -- there is no real class left at runtime for `new T()` to instantiate. `new` requires a genuine, concrete class to allocate; T is only ever a compile-time placeholder telling the compiler what type checking to perform, not something that survives into the compiled class file. The compiler catches this immediately, rather than letting it fail at runtime, because it already knows T won't exist by then. WHY THIS WORKS AS AN ANSWER ------------------------------ This reproduces exactly the `new T()` limitation the chapter names as a direct consequence of erasure, and the explanation ties the failure back to the chapter's own claim that the type argument doesn't exist at runtime, so there's nothing concrete for `new` to construct.