The Nutshell series published by the O'Reilly group has become so ubiquitous in the IT world that it needs very little introduction. As the preface of C# in a Nutshell states, the aim of the series is to become the desktop reference for whatever technology is covered by each book. In this case, O'Reilly aims to make this book the must-have reference for all C# programmers. This review will focus on the points that any good reference book should address, namely: brevity, completeness, correctness, and usefulness. Unfortunately, my own personal knowledge of C# is restricted to what was discussed in .NET Essentials (another O'Reilly publication), so I won't be able to be as critical of the correctness as I would like. My conclusions are thus based on short tests that I ran to check the validity of the claims made in the book.
C# in a Nutshell scores high marks in both the brevity and correctness categories. Humorous as it might be to label an 830-page book as brief, it actually qualifies as such. The main discussion of the language is kept to the first 270 pages, with an average of about 20 pages devoted to each subject. Only the essentials are discussed, and that will usually be enough when you need to quickly look up how to do something. The remaining 560 pages are devoted to a Quick Reference of the .NET framework classes. While reading the text, I never came across any glaring inconsistencies, such as conflicting descriptions of how to accomplish a task, which leads me to suspect that the text is mostly correct. The few actual tests I ran worked as expected. On a superficial level, I found the content credible.
When it came to completeness, I wasn't as impressed. As a reader, I have somewhat of a personal bias: I'm pretty familiar with both C++ and Java. I also suspect that this knowledge is shared by a large percentage of this book's audience. As a consequence, I found myself wishing that the advanced features particular to this language had been covered more thoroughly, and that the description of features shared by C++, Java, or both, had been trimmed down a bit. I found the sections on Custom Attributes, Serialization and Threading to be especially light, given that they are all core features of the C# language. I also found the two sections dealing with integration of legacy components (DLLs and COM) to be somewhat inadequate for professionals who actually need to deal with these issues. However, I do understand the balancing act that has to be done to keep this book brief. I would have wanted more emphasis on the unique features and considerations associated with this new language, and less on the basics. On the other hand, the authors should be commended for the range of topics they manage to touch on in such a small number of pages. Certain topics, such as Diagnostics and Command-line tools, are fully described and could easily have been forgotten.
My real beef with the completeness of this book is related to the 500+ page SDK Quick Reference. Let's start with the good: The descriptions of the classes and their uses are verbose, and useful. The Quick Reference is logically divided up according to the .NET package divisions, and each description includes a very good UML diagram showing you where each class fits into the grand scheme of things. Now the bad: Though the class interfaces are fully detailed, there is no description whatsoever of the actual method parameters, and how they will be used internally. From a programmer's perspective, this is extremely annoying. Here's an example of what I mean: The class System.Timers.Timer has a property called interval that can be set through the constructor, or through property accessors. Without a proper description, one might imagine that this property relates to the interval at which the Timer does what it does (in this case, throws an Event.) However, we have no idea what units the interval property is using. Do we specify the units in seconds? In milliseconds? In nanoseconds, even? We have no idea, and we can only figure it out by trying it ourselves. You can imagine how frustrating this would be for properties where the answer is not so easily discovered.
The second major issue I have with this book is the unadvertised omission of the System.Windows.Forms and System.Web namespaces in the Quick Reference. It seems as if these GUI-related namespaces have been saved for Programming C#, but I found their omission in this book to be questionable, at the very least. I wouldn't complain if the namespaces were at least described briefly in the Quick Reference, but they aren't even mentioned once. This choice renders the book practically useless on its own for anyone who wishes to add a visual interface to his or her program, which, unless you're writing server code, is nearly everyone. I think that if the goal of this book is for it to be the only desktop reference you'll need, then in this respect it has failed. Similar to the Java in a Nutshell / JFC in a Nutshell combo, you'll probably need both this book and Programming C# for a complete reference from O'Reilly.
All in all, it is hard not to recommend this book for anyone who plans to work with C#. Its description of the language basics is thorough, the advanced features are at least brought up and discussed, and the reference, for all its flaws, will be considered useful by most. In particular, I appreciated the UML diagrams included in the book, placing it one step ahead of the Microsoft documentation. However, the book is somewhat incomplete, and you will most likely want to get Programming C# (convenient, isn't it?) and keep that bookmark to Microsoft's online documentation, at least to look up what the function parameters actually do.