A C# Reading List by Eric Lippert (ZZ)
//z 2012-5-18 10:29:00 AM IS2120@CSDN
The C# Programming Language, 4th edition by Anders Hejlsberg, Mads Torgersen, Scott Wiltamuth and Peter Golde
Essential C# 4.0 by Mark Michaelis
C# In Depth, 2nd Edition by Jon Skeet
Effective C#, 2nd Edition by Bill Wagner
More Effective C# by Bill Wagner
A C# Reading List by Eric Lippert
//z 2012-3-28 15:04:03 PM IS2120@CSDN
C# expert Eric Lippert discussessome of the books he recommends to others and cannot live without himself.
Eric Lippert is a PrincipalDeveloper on the C# compiler team at Microsoft and a member of the C# languagedesign team. His blog,FabulousAdventures in Coding, is mostly about the design and implementationof programming languages, but also makes occasional forays into subjects heknows next to nothing about, like piano tuning, large-scale electrical powersystem safety, and relationship advice. He’s also a frequent contributor to the C#tag on StackOverflow. When not writing about programming languageshe can be found attempting to keep histiny sailboatupright in the middle of the Puget Sound.
As someone who reads and edits a lotof programming books, I’m often asked for book recommendations. Here are someof my favorites:
Sams Teach Yourself Visual C# 2010 in 24 Hours byScott Dorman
//z 2012-3-28 15:04:03 PM IS2120@CSDN
I’m not thrilled with the title – I strongly agree with Peter Norvig, who oncenoted thatten years ismore like the amount of time it takes to really master a difficult craft.But I am thrilled with the contents; for the money, this is a really solid bookfor the beginner C# programmer. What I particularly like aboutScottDorman’s book is that he does not make the pedagogical error made bya lot of other “beginner book” writers of introducing the material in the orderhe learned it; rather, he introduces the material in order of increasingcomplexity, even if that does not mimic the historical development of thelanguage.
These two are the books I recommendmost often for the intermediate-to-advanced C# developer. ThoughMark Michaelis’s book does have a fair amount ofinformation for the beginner C# developer, it best serves either somewhatexperienced C# developers or developers experienced in other languages who arecoming to C#.StackOverflowlegendJonSkeet’s book assumes that the reader is already familiar with thebasic features that have been in the language since C# 1.0. Both books arewell-named:Essential C# delivers the essential information you need,andC# In Depth really goes into depth on some of the more obscurecorners of the language. Both books concentrate heavily on the C# languageitself, with occasional forays into describing the broader .NET infrastructure.I also particularly like Jon’s dry British humor laced throughout the book.
Neither of these books are in anyway tutorials for the beginner programmer; rather, each delves into fiftyspecific and often subtle aspects of achieving high-quality C# coding. Thesebooks help the reader understand those language specifics at a deep level.BillWagnerreally gets it; he always explains difficult subjectsboth clearly and accurately. If you want to read even more about the best (andworst!) practices of C# developers, also check outBill’s articles on the MSDN Developer Center.These books and Bill’s articles help make good C# programmers into great ones.
The C# Programming Language, 4th edition byAnders Hejlsberg, Mads Torgersen, Scott Wiltamuth and Peter Golde
This is of course the one book Icannot live without; it is constantly open on my desk and full of post-it noteannotations. It is the definitive specification and explanation of the C#language, containing more information than even the MSDN documentation on thelanguage. Though you can conveniently download the specification for free, I recommendthat people also consider buying the print edition. The print edition isannotated by a large number of C# experts, including myself and theaforementioned Jon Skeet and Bill Wagner. The annotations point out, explainand justify some of the trickier points of language design that thespecification itself glosses over.
I’m extraordinarily fortunate inthat I’ve had Anders, Mads, Scott and Peter sitting down the hall from me forthe last six years. You don’t have that benefit, but the next best thing tobeing able to ask the design team in person for an explanation of how C# worksis to have their book within arm’s reach. Get the specification!
Java Puzzlers by Joshua Bloch and Neal Gafter
One might wonder what on earth isthis book doing on my list of books for C# programmers, particularly since I’venever written so much as a line of Java code. I love three things about thisbook: First, it was written with such an evident sense of fun. Second, everydevious trap that Neal Gafterand JoshuaBloch lead the reader into is actually a lesson for languagedesigners; if the developer is falling into a trap, that’s the fault of thelanguage designers for not making the trap easier to avoid. Third, over half ofthe pitfalls, traps and corner cases described in this book cause theequivalent C# program to produce a warning or error! The best mistakes to learnfrom, in language design and in life, areother people’s mistakes.
I am extremely fortunate to haveworked with Neal on the C# design and implementation team for several yearsnow, and we enjoy presenting similar C# puzzles to our coworkers and customers;perhaps someday we’ll write aC# Puzzlersbook.
These last two books have nothing todo directly with C# at all, but nevertheless I consult them frequently. I seeIntroductionto Algorithms on many bookshelves in Microsoft offices; there is a reasonwhy people are still hauling around this enormously thick and heavy book fromtheir undergraduate days. It is a great reference when you need to refreshyourself on the details of how to balance a binary tree or deduce theasymptotic efficiency of an algorithm from first principles. Many professionaldevelopers with CS degrees do not use the theoretical principles they studied ona daily basis, but we on the compiler team certainly do. And line-of-businesssoftware developers can also benefit from having a solid understanding of CSprinciples.
We are in a bit of a functionalprogramming renaissance right now. Functional languages like F# are gaining inpopularity, and ideas from purely functional programming languages are makingtheir way into mainstream object-oriented languages. LINQ in C# and VisualBasic, for example, was heavily influenced by Haskell-style monadic query comprehensions.Also, purely functional data structures work well in highly concurrentprograms, which we’re seeing more and more of as many-core machines continue tofall in price. The big thick algorithms book is primarily concerned withtraditional data structures full of mutable arrays, stacks, queues and so on;Chris Okasaki’s thin, elegant book is a great survey of how to build somepretty complex data structures out of immutable, threadsafe, memory-efficientparts. A lot of the material in the book is also available in his thesis, whichis availableonline.The comparatively terse syntax of the coding examples of his book take somegetting used to for C# programmers; F# programmers will have a much easiertime.
CLR via C# is by all accounts an excellent book;however, I have never read it myself. (I had no need to learn about theCLR via C#; I learned about the CLR via the CLI specification.) In goodconscience I can only recommend books that I've actually read.
I've met Jeff a couple of times and he's a perfectly nice fellow; I havenothing against him whatsover. It simply never occurred to me to *recommend* abook that I have not read and do not own. If you think it's reasonable torecommend books that you have not read and do not own then, well, I guess youand I disagree on that point. Similarly, I don't think it is reasonableto publically insult people I don't know; you and I disagree on that alsoit seems.