This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Avoid it by using generics only when there's a good reason to. In the example they've given...why would you do that? What problem would you try and solve in that way? All they mean by it (I think) is that they've made up a very artificial example that is designed to illustrate how generics work rather than to solve a problem.
It doesn't look especially ridiculous to me. However since it's a typical SCJP example with no relationship whatsoever to the real world, you wouldn't expect it to be especially meaningful anyway. And it isn't. It's rather pointless. But I wouldn't go so far as to call it "ridiculous".
Joined: Sep 23, 2010
"ridiculous" is used in K&B book. Wondering, which statement is bad