Difficulty: Easy
Correct Answer: Only those procedures labeled as Generic are generic.
Explanation:
Introduction / Context:
Generic procedures (generic methods) are methods that declare their own type parameter list independent of whether the enclosing type is generic. This question checks the basic definition and scope of “generic” at the method level.
Given Data / Assumptions:
Concept / Approach:
Only methods that explicitly declare type parameters are generic methods. Being defined inside a generic class does not automatically make every method generic; such methods can still be non-generic and simply use the class’s type parameters. Conversely, a non-generic class can contain a generic method.
Step-by-Step Solution:
Verification / Alternative check:
Write examples: a non-generic class with method M
Why Other Options Are Wrong:
They misstate scope (A), impose false limits (C), or rephrase the definition in a way that is less precise for identification (D).
Common Pitfalls:
Confusing “uses a generic type parameter from the class” with “is itself a generic method.”
Final Answer:
Only those procedures labeled as Generic are generic.
Discussion & Comments