Want to be a better developer?

person Matt Honeycuttfolder_open.net, Best Practicesaccess_time May 13, 2010

I’ve been trying to put together a link list of things that have helped me improve as a developer over the last couple of years.  This is far from complete, but it’s a start.  I’m not saying this is an absolute "you have to know these things" list or that it will work for everyone out there, it’s just things I’ve found to be really helpful for me.  As always, your mileage may vary. 

  • SOLID Principles – These principles have helped me a ton.  They aren’t rules to be followed blindly, but I’ve found that understanding the reasoning behind them and trying to strive for code that adheres to them generally makes things easier (and also more fun) in the long run.  Now when I’m faced with a design choice, I usually ask myself which alternative is more SOLID and go with that.  Be sure to check out the SOLID “motivational” posters over at Derick Baily’s blog.
  • Design Patterns – Certain types of problems tend to recur in software development.  For these, we have design patterns.  Getting a handle on design patterns is something that only comes with practice.  You won’t be able to memorize and recognize even the “core” set of patterns immediately, but over time you will likely find yourself recognizing when to apply them more and more often. I strongly recommend Head First Design Patterns (yes, the code samples are in Java, but the patterns themselves are what’s important, and a C# dev should have no problem following along).  It provides a very good introduction to design patterns.
  • Test Driven Development – I think a lot of new developers hear “testing” and immediately glaze over, but I actually enjoy practicing TDD.  It doesn’t just help me test my code, it helps me design my code.  That’s a big advantage that a lot of people overlook.  It also gives me confidence that the class I’m creating does exactly what it is supposed to do, and nothing more.  If you aren’t sure how to do TDD, you can watch one of the various TDD Katas online, such as the String Calculator at Roy Osherove’s site or the Bowling Game at ‘Uncle’ Bob’s site. 
  • Resharper 5 – Resharper is essential for doing C# development in my opinion.  Out of the box, it will suggest lots of little things that can help improve your code.  It helped me learn LINQ by offering to convert ugly for/foreach loops into clean, elegant LINQ expressions, and it finally convinced me that ‘var’ isn’t always evil. 
  • NHibernate and FluentNHibernate – I prefer NHibernate to Castle ActiveRecord these days; the ActiveRecord pattern isn’t as flexible or as extensible as an implementation of the repository pattern based on NHibernate, and I’ve run face first into that wall on more than one occasion.  FluentNHibernate makes it a lot easier to get up and running with NHibernate since it hides the XML and provides other nice helpers to get you started.  
  • Lambda expressions – These are essential when working with C# 3.0 or later.  They’re a bit hard to grasp at first, but they open up very interesting re-use possibilities, and lots of APIs leverage them heavily. FluentNHibernate uses them to setup mappings, and StructureMap uses them for its embedded Domain-Specific Language (DSL). 
  • Generics – This is an older C# feature, but understanding generics is still just as essential today as ever.  Beyond leveraging the built-in generic classes from the base-class library, learning to wield generics also opens up new avenues for creating clean, extensible, and reusable classes.
  • StructureMap (including its AutoMocking container) – One of the biggest "lightbulb" moments I’ve had recently was adopting StructureMap and IoC-everywhere.  This totally changed how I code.  Now when I realize a class I’m working on is going to need some other ‘service’ to fullfill its responsibilities, I simply create a new service interface and add it to my class’s constructor.  This makes doing top-down development much easier.  Once I’ve finished the tests and implementation for the class I’m working on, I can turn my attention to creating the class that fullfills the service interface. 
  • LINQ – A lot of people focus on LINQ to SQL, but LINQ is more than that.  LINQ to Objects is incredibly useful. Instead of complicated foreach loops that filter or project objects, I find myself writing short, elegant LINQ queries instead. Be sure you learn about all the various extension methods and keywords, including things like ‘select…into’ and ‘let’. 
  • Moq – Mocking frameworks allow you to configure stubs or fakes that you can substitute for dependencies while testing your classes.  While they can indeed be abused, they are still quite useful.  Moq is my personal favorite for its fluent, lambda-based syntax.  Combine it with the adapter pattern, and you can even use it to fake or stub dependencies on base-class library types.
  • ASP.NET MVC and MVCContrib – If you are going to make an ASP.NET application, do yourself a favor and go the MVC route.  While the drag-and-drop appeal of WebForms can be hard to resist, you will inevitably find yourself fighting its leaky abstractions and lack of flexibility as your application scales.  Out of the box, ASP.NET MVC is still quite bare-bones, and you may find yourself having to focus on issues that are more “plumbing” and less “application”.  Be sure to check MVCContrib before you start reinventing the wheel.  With things like portable areas, fluent control builders, test helpers, and a slew of HtmlHelper extensions, it’s surprisingly easy to build maintainable, testable ASP.NET applications by leveraging MVCContrib and ASP.NET MVC. 

Aside from that, I also follow numerous blogs on development.  If I had to trim Google Reader down to only two dev blogs, they would probably be:

  • Ayende @ Rahien – Creator of more open-source .NET software than probably anyone, Ayende is one of my “code heroes”.  I’ve learned a lot from his blog and by reading the code of his various projects.
  • Los Techies – The number of really smart people blogging here makes it a must-read.  I’ve absorbed a lot of new ideas and information from this place.  

I’m sure I’m overlooking something.  Let me know what you’ve found most helpful in improving your developer chops in the comments.

Comments

  1. Hey – nice blog, just looking around some blogs, seems a pretty nice platform you are using. I’m currently using WordPress for a few of my sites but looking to change one of them over to a platform similar to yours as a trial run. Anything in particular you would recommend about it?

  2. Hi,When I first came upon your blog I thought wow! this looks great – must follow.

  3. Took me time to read all the comments, but I really enjoyed the article. It proved to be Very helpful to me and I am sure to all the commenters here! It’s always nice when you can not only be informed, but also entertained! I’m sure you had fun writing this article.

  4. Nice post. You’re in RSS now so I can see more from you down the road.

  5. Hi there, I need to mention it is a smart post. Such insighful writing is rare these days. Informed comment like this has to be lauded. I’ll certainly be looking in on this blog again in the near future.It would be stunning if you could join us at <a href="http://findmesomeone.org">time together</a>

  6. just letting you know – your site is fantastic!

  7. Hah ijust wrote something like this in my profile.

  8. Who can post an article in an article directory? Anyone who wishes to post an article can do that for free in our article directory, but if you are a customer of ours then its our responsibility to publish your article not only in our directory but also in all other article marketing directories. http://www.allartsdir.com.

  9. I get about 20k visitors per month I was wondering if you are interested in building a network of blogs together…. my blog is http://phoneontherun.com/forum_i68_en/index.php?action=profile;u=2596

  10. So beautiful sharing!Thank you very much.

  11. Aw, this was a really quality post. In theory I’d like to write like this too – taking time and real effort to make a good article… but what can I say… I procrastinate alot and never seem to get something done.

  12. Excellent read, I just passed this onto a colleague who was doing a little research on that. And he actually bought me lunch because I found it for him smile So let me rephrase that: Thanks for lunch!

  13. Hi! I was surfing and found your blog post… nice! I love your blog. 🙂 Cheers! Melissa. G.

  14. Took me time to read all the comments, but I really enjoyed the article. It proved to be Very helpful to me and I am sure to all the commenters here! It’s always nice when you can not only be informed, but also entertained! I’m sure you had fun writing this article.

  15. Software Engineers will love your port. But some paragraphs not easy to understand such as the last one. I’m waiting for your explanation.

  16. Sorry for the huge review, but I’m really loving the new Zune, and hope this, as well as the excellent reviews some other people have written, will help you decide if it’s the right choice for you.

  17. Most from the tees that came out shortly after this one in no way actually caught on. Golfers maintain using the tiny mounds of sand to tee off with. Tees didn’t really catch on until the 1920’s when Dr. William Lowell, Sr. decided to mass product them. This well-known tee was made wood making use of a flared out top and it absolutely was painted red so it would be effortlessly visible within grass. This new tee was referred to as the Reddy sort. Pro golfers Walter Hagen and Joe Kirkwood, Sr. promoted this new item and assist it get off the ground and turn out to be the most nicely identified and use tee.

  18. Excellent read, thanks

  19. I really love what you write here,very refreshing and intelligent. One issue though, I’m running Firefox on Linux and parts of your content are a little off. I realize it’s not a common setup, but it’s still something to keep an eye on. Just shooting you a heads up.

  20. Pretty good post. I just stumbled upon your blog and wanted to say that I have really enjoyed reading your blog posts. Any way I’ll be subscribing to your feed and I hope you post again soon.

  21. I’ve have to tell you, u r friggin on. I clicked on your website from another site and am really interested in this learning about this. Do you mind if I comment to this info from my fan page?

  22. This article gives the light in which we can observe the reality. this is very nice one and gives indepth information. thanks for this nice article!

  23. The new Marketing Secret Weapon makes $19,506.21 a Month in just 18 Clicks…http://tinyurl.com/making-money-in-15-minutes

  24. love the blog, thanks for sharing your thoughts

  25. There are certainly a lot of details like that to take into consideration.

  26. I was looking for a good article covering Try-Catch-FAIL – Want to be a better developer?. Searching in Google I finally found this great blog post. After going over this article I’m really happy to say that I have found just what I was searching for. I will make sure to remember site and come again more often . Thanks! 🙂

  27. If every editor wrote like you believe me the world would be a better place! This was an excellent read expecting more!

  28. Interesting take on this issue. I for one have seen many twists on this and can often spot the holes in the arguement however, on this occasion I belelive your writing is such that everyone should be in agreement with this. Thank you for sharing it with us.

  29. If you’re still on the fence: grab your favorite earphones, head down to a Best Buy and ask to plug them into a Zune then an iPod and see which one sounds better to you, and which interface makes you smile more. Then you’ll know which is right for you.

  30. do you like turtles?

  31. Nice site,i have bookmarked it for later use, thanks.

  32. I recently came across the site and wanted to say great job.

  33. With Tiger Woods third victory at the 2008 US Open, it can only be a matter of time before he joins the illustrious golfers with four wins, and who knows, maybe he will go into the golfing history books with 5 wins or more. Did you know that a European has not won the event since 1970, when Tony Jacklin from England won? Another Englishman, Lee Westwood, had a chance in the 2008 event but missed a 15 foot birdie putt about the last hole.

  34. Excellent read, I just passed this onto a colleague who was doing a little research on that. And he actually bought me lunch because I found it for him smile So let me rephrase that: Thanks for lunch!

  35. Who do you guys use to print photos?

  36. Thanks for sharing this important code with us.Keep posting us informative post to us.

  37. Great list. I would also add Machine.Specifications for Behaviour Driven Development, and also AutoMapper – a great tool when developing in MVC.

  38. Good additions! I have yet to use Machine.Specifications in a real project, but I do indeed use/abuse AutoMapper quite frequently. 🙂

  39. I’ll gear this review to 2 types of people: current Zune owners who are considering an upgrade, and people trying to decide between a Zune and an iPod. (There are other players worth considering out there, like the Sony Walkman X, but I hope this gives you enough info to make an informed decision of the Zune vs players other than the iPod line as well.)

  40. These kind of post are always inspiring and I prefer to read quality content so I happy to find many good point here in the post, writing is simply great, thank you for the post http://www.theheartratemonitors.com

  41. I’ve gotta advise you, you are totally on. I stumbled your blog from another site and am totally fascinated by this niche and learning more. Do you mind if I quote to this info from my subscribers group?

  42. Lots of confusion here. H.264 and Ogg are codecs. Flash, HTML5, qt are players. Flash uses h.264 too. There are two battles on going, the web player and the codec for HTML5. Apple made a choice between investing in Ogg to flesh out any unknown patent issues and prong it up to speed or invest into a known codec. Open source is all fine, but sometimes as a businesss it makes sense to put your money on the known technology.

  43. This article gives the light in which we can observe the reality. this is very nice one and gives indepth information. thanks for this nice article!

  44. This is a really good read for me, Must admit that you are one of the best bloggers I ever saw.Thanks for posting this informative article.

  45. nice. this blog is getting updates?

  46. I’ve been looking for a while for a good read regarding Try-Catch-FAIL – Want to be a better developer?. Searching in Bing I found this great blog post. After reading this post I’m glad to say that I have a good feeling I found just what I was looking for. I will make sure to save this website and check it out regularly . Thanks! 🙂

warningComments are closed.