Feeds

Java Puzzlers

Excellent!

  • alert
  • submit to reddit

Reducing security risks from open source software

Book review 'Java Puzzlers' is unlike any Java book we've seen before. Promising the reader an exploration of 'traps, pitfalls and corner cases', this is by turns entertaining, infuriating and downright puzzling. It is also truly illuminating, and serves to educate while it entertains. One would expect no more from the combined talents of Joshua Bloch (author of the classic Effective Java, one of our most highly recommended intermediate/advanced Java titles), and Neal Gafter (formerly of Sun and now Java evangelist at Google).

The book consists of 95 puzzles themed across ten chapters. Most puzzles consist of a small block of seemingly innocent code and a straightforward question. But the appearance of simplicity is usually deceptive and the puzzles cast a light on some quirk, trap, pitfall or ambush. Occasionally there's no code and the puzzle is for the reader to supply the code to answer the question. And, like the best puzzles, these ones grab the reader and don't let go. This is not a book that you can read passively. It's also a lot of fun.

While this isn't the sort of book that we'd recommend to the complete beginner, anyone competent with Java will find the contents engaging and challenging. Getting the right answer gives a real buzz, but even if your answers are mostly wrong you'll learn something in the process. And it's doubtful that anyone, no matter how good they are, will skate through this book and not get tripped up along the way.

There's a serious intent behind the book as well and that is it does high-light the traps that await the unwary. With frequent references back to the Java language specification and to Effective Java, this is a book that warns of suspect practices and points out the source of hard-to-find bugs and odd program behaviour. It's educational in the best sense of the word.

An appendix provides a complete listing of all the traps and pitfalls high-lighted by the puzzles, along with a word of advice on how to avoid the problem in the first place. It's good advice but not half as much fun as working through the puzzles in the first place.

Mention must also be made of the design of the book. It's put together in such a way that the solutions to the puzzles always appear over-page, so there's no chance of accidentally getting sight of the solution as you're reading the question. The book is also illustrated with optical illusions which add to the pleasure.

What more can we say? It gets a very hearty recommendation.

Title: Java Puzzlers

Authors: Joshua Bloch and Neal Gafter

Publisher: Addison Wesley

ISBN: 032133678X

Media: Book

Level: Intermediate/Advanced

Verdict: Excellent!

The Power of One eBook: Top reasons to choose HP BladeSystem

More from The Register

next story
NO MORE ALL CAPS and other pleasures of Visual Studio 14
Unpicking a packed preview that breaks down ASP.NET
Apple fanbois SCREAM as update BRICKS their Macbook Airs
Ragegasm spills over as firmware upgrade kills machines
Cheer up, Nokia fans. It can start making mobes again in 18 months
The real winner of the Nokia sale is *drumroll* ... Nokia
Mozilla fixes CRITICAL security holes in Firefox, urges v31 upgrade
Misc memory hazards 'could be exploited' - and guess what, one's a Javascript vuln
Put down that Oracle database patch: It could cost $23,000 per CPU
On-by-default INMEMORY tech a boon for developers ... as long as they can afford it
Google shows off new Chrome OS look
Athena springs full-grown from Chromium project's head
Apple: We'll unleash OS X Yosemite beta on the MASSES on 24 July
Starting today, regular fanbois will be guinea pigs, it tells Reg
prev story

Whitepapers

Top three mobile application threats
Prevent sensitive data leakage over insecure channels or stolen mobile devices.
Implementing global e-invoicing with guaranteed legal certainty
Explaining the role local tax compliance plays in successful supply chain management and e-business and how leading global brands are addressing this.
Boost IT visibility and business value
How building a great service catalog relieves pressure points and demonstrates the value of IT service management.
Designing a Defense for Mobile Applications
Learn about the various considerations for defending mobile applications - from the application architecture itself to the myriad testing technologies.
Build a business case: developing custom apps
Learn how to maximize the value of custom applications by accelerating and simplifying their development.