C# 4.0 in a Nutshell

image

C# 4.0 in a Nutshell, Fourth Edition

I’d normally put a disclosure at the end of a post, but as I was one of the reviewers for this book, and Joe Albahari gave me a copy, I felt I should mention this up-front.

That said, it doesn’t alter my opinion: if you program in C#, you owe it to yourself to have a copy of this book to hand. It will improve your understanding of C# and the .NET framework; it will improve the code you write and I suspect it will pay for itself the first time you pick it up.

This just released fourth edition is expanded upon the previous, and at slightly over 1000 pages I’m not sure how much longer the ‘nutshell’ tag will be appropriate! (Not the fault of the authors, more the evolution of C# into a mature language with many features). It includes coverage of new topics such as parallel programming, code contracts, dynamic programming, security, and COM interoperability. In all, there are 26 chapters covering the basics right through to the more advanced topics of threading and parallel programming. There is a comprehensive section on LINQ, including examples that work with both LINQ to SQL and Entity Framework.

The code examples and explanations are concise, extremely clear and easy to understand. The code examples from Chapters 2 – 4, 6, 8 – 10 and 24 are freely available as part of LINQPad, a very useful tool written by author Joe Albahari (and downloadable from http://www.linqpad.net/ )

I’m a fan of the format O’Reilly use in their books, and in particular it seems like it could have almost been created with this book’s authors in mind, as it complements their lucid writing style and aids the flow of the text . Very few books could proclaim on the front cover that they are “The Definitive Reference” and it actually be true. This book does and is. But it’s not just a reference. It will benefit newcomers and seasoned developers alike.

The only slightly disappointing thing is the Index. Joe informed me that he knew about this; it seems something went awry during the publishing process, and a less than stellar index was included. Let’s hope that future reprints have an updated index. There is of course a searchable electronic version available. Update: Joe has informed me that the index was updated.

It would be pointless to go into any more detail, as I would no doubt be unable to the book the justice it deserves. A full contents list is available at the O’Reilly link above. I was honoured when Joe Albahari asked if I would be one of the reviewers, and I was humbled by the credentials of the other reviewers. Many thanks to Joe and Ben for writing such a useful book.