<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>FormatException &#187; Programming Standards</title>
	<atom:link href="http://www.formatexception.com/category/programming-standards/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.formatexception.com</link>
	<description>Ramblings on developing in the Windows World</description>
	<lastBuildDate>Mon, 24 May 2010 15:43:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Programming for Maintenance</title>
		<link>http://www.formatexception.com/2010/02/programming-for-maintenance/</link>
		<comments>http://www.formatexception.com/2010/02/programming-for-maintenance/#comments</comments>
		<pubDate>Wed, 10 Feb 2010 15:07:58 +0000</pubDate>
		<dc:creator>Brian</dc:creator>
				<category><![CDATA[Programming Standards]]></category>
		<category><![CDATA[maintenance]]></category>

		<guid isPermaLink="false">http://www.formatexception.com/?p=270</guid>
		<description><![CDATA[Code Complete defines Maintainability as &#8220;The ease with which you can modify a software system to change or add capabilities, improve performance, or correct defects.&#8221;
I&#8217;ve been thinking for awhile now about this post and I&#8217;ve been unsure of exactly what needs to be here.  I know I&#8217;ve done a lot of maintenance work.  It&#8217;s inevitable.  [...]]]></description>
			<content:encoded><![CDATA[<p>Code Complete defines Maintainability as &#8220;The ease with which you can modify a software system to change or add capabilities, improve performance, or correct defects.&#8221;</p>
<p>I&#8217;ve been thinking for awhile now about this post and I&#8217;ve been unsure of exactly what needs to be here.  I know I&#8217;ve done a lot of maintenance work.  It&#8217;s inevitable.  You name the field and chances are we&#8217;ve developed something for it.  A lot of the software we develop we do so because there just isn&#8217;t commercial off the shelf (COTS) software for the business process.  COTS is for the broad market.  So customers come to us when COTS doesn&#8217;t meet their needs.</p>
<p>Which gets us to maintenance.  We try the best we can but in any software application there will be bugs.  It is inevitable, it is a fact of life.  Unless you are just writing a &#8220;Hello World&#8221; program there will be people who use your product in ways you didn&#8217;t expect.  We have had clients who take the application we&#8217;ve written for them and walk away.  Not because they&#8217;re unhappy but because the cost to fix every single bug and add in every feature they want can often be prohibitive.  They&#8217;re happy where the app is and that&#8217;s good enough.</p>
<p>Most clients stay with us for a maintenance tail.  They prioritize the bugs they want fixed and features they want added and budget accordingly.  We want happy clients, it&#8217;s that simple.  The happier they are with us the more work they bring to us.  This is common across all businesses, whether you&#8217;re a dry-cleaner or doing software services, a happy client is good.</p>
<p>So in software services how do you make a client happy?  In my experience it&#8217;s been minimizing maintenance tail costs.  But how do you do this?  I&#8217;m going to try and sum up where I have noticed problems.  I could reprint Code Complete here and say, &#8220;There, that&#8217;s how you do it&#8221; but that would be meaningless.  The point of this post is to focus on a few key points.</p>
<p>1.  The obvious:  Requirements, requirements, requirements.<br />
As much as possible try to impress upon your clients the importance of requirements.  The more requirements analysis and design that is done up front before even beginning development the cheaper the maintenance tail.  It&#8217;s fact the earlier you find a problem the cheaper it is to fix. (Code Complete, Table 3-1, Average Cost of Fixing Defects Based on When They&#8217;re Introduced and Detected)</p>
<p>The biggest problem with this?  Most of the time clients don&#8217;t know what they want.  That&#8217;s right, they come to us and say, &#8220;Well, I want an application that does this.&#8221;  But what does that mean?  Does this need to mirror an existing business process?  Is it something completely new?  Do you have an idea of how the process should flow?  Do you know where you get your data and where it should go?  What kind of reporting are you going to need? (Customers never know that last one)</p>
<p>A lot of time we end up building up an existing business process in order to understand what needs to be developed for the application.  That&#8217;s okay.  I can accept that business analysis may be a part of the job.  So this is key:  (most of the time)  Clients don&#8217;t know what they want.  They will usually have a generally vague idea but you will have to help them.  Try to come up with a basic set of requirements.  Next, at a minimum, whip out Visio (there are better products out there but Visio is probably the most common) and throw together a few pages of the app.  Put together some sort of flow.  Help them bring their vision to reality.  Only then will they really begin to understand their own requirements and process.  Only then will they see what&#8217;s there and what&#8217;s missing.  Most clients can&#8217;t envision software.  They&#8217;re paying money for something that is completely virtual and just can&#8217;t see the final product.</p>
<p>Now, this is all well and good.  The problem is that a lot of clients don&#8217;t want to spend several weeks (or longer) designing the app, they want to get moving on it.  This leads to iterative development.  It&#8217;s more expensive.  But done properly I&#8217;ve still had happy clients.  Prioritize parts of the application.  Model a couple of those pages, build it, move on.  You will have problems.  I had one client who missed telling us about a key part of data for the app.  The ERD we had didn&#8217;t support this new data so we had to build out some new tables and fix everything.  This was after we&#8217;d done requirements and modeled the pages.  It wasn&#8217;t until the app was in beta that he went, &#8220;Oh, and you need to put this in there.&#8221;</p>
<p>2.  Naming Conventions: Use it, love it<br />
This is going to sound stupid but one of the biggest problems I&#8217;ve had coming in to maintain an app I didn&#8217;t design or build is naming conventions.  Even if the names are consistent and meaningful, when there is no standard across an application where multiple developers have been working on it, it takes way too long to understand everything.  I&#8217;m not saying that your company should enact a strict naming convention company wide.  That would be nice but it&#8217;s not reality.  Your project lead, however, should.  Even if you&#8217;re working under different project leads you need to adapt.  This is especially true in this polyglot world of development.  At one time I was working on a PHP project, a java project and a C# project.  Each has their own naming conventions.  Yes, it took longer when I had to switch projects to re-orient myself but that in and of itself is the nature of polyglot programming.  I know that when someone comes behind me to maintain the app (and in a lot of cases it&#8217;s even me) it is a hell of a lot easier to get going on maintenance when there is some sort of naming convention across the app.</p>
<p>So what do I mean by naming conventions?  Method names, event and delegate names, variable names.  If it takes a name there needs to be a standard.  Whether it&#8217;s public, private, static, constant, an enum or class, there needs to be a standard.  The only place I haven&#8217;t seen a need for naming conventions is internal to methods.  If the app is coded right and adhering to basic OOP methodology variables internal to a method shouldn&#8217;t be around that long.  They still should be meaningful but I don&#8217;t care if you want to put an underscore in front of your internal variables or not.  I don&#8217;t care if you want to capitalize them or not.  Anytime I have to walk through from class to method to class to method to delegate to method there better be some sort of convention.  Otherwise it costs the client money.  There will always be some sort of spin-up when entering maintenance.  Just try and minimize it.</p>
<p>So you&#8217;ve got your requirements and naming conventions, what&#8217;s next?</p>
<p>3.  OOP, if you use it, use it<br />
The biggest trouble I&#8217;ve had, excepting those mentioned above, are projects where developers seemed to take a procedural approach to OOP.  God classes and methods (functions?), poor use of inheritance and virtually no use of interfaces.  This makes maintenance tough.  I have to admit I myself was bit lacking in this area out of college.  Sure I took an OOP class, sure I had the theory but applying the theory is wholly different then having the theory.  And I&#8217;m not the only one.  It seems one of the universal constants having new engineers on my team fresh out of college is that they can&#8217;t apply OOP.  This often also applies to self-taught programmers who many times don&#8217;t even have the theory.</p>
<p>I want a black box (Code Complete, Encapsulate Implementation Details, Information Hiding).  When I step into a method during troubleshooting I want to only go into that method once.  There after I want to trust that the method works as intended.  I want a method to only do one thing and not affect parts outside of itself.  If I have a login control it should only be doing login.  I want a class to default all properties (getters/setters) to private.  I don&#8217;t want those variables being changed outside the class unless they need to be.  I want interfaces(Code Complete, Form Consistent Abstractions).  It seems like this is the least understood by programmers straight out of college.  So often new engineers like to inherit and override.  Obviously this has it&#8217;s time and place.  But think if this really is needed or if you just need to create an interface (Code Complete, Inherit-When Inheritance Simplifies the Design).</p>
<p>I digress, I&#8217;m starting to write out Code Complete.  If nothing else, use and apply Code Complete, 5.3 Design Building Blocks: Heuristics.</p>
<p>So how to fix this?  If you have an engineer on your team that you&#8217;re not familiar with do a code review.  Assign him a task and take a look at his code.  I don&#8217;t think I carry the title Senior Software Engineer because I such a great programmer.  Really I barely consider myself adequate.  I have seen a lot of code, written a lot myself, I lead teams pretty well as a project lead and clients like to work with me.  If you&#8217;re leading a project remember the code of the engineers underneath you is your responsibility.  Yeah, you might ruffle some feathers.  We programmers take our code personally.  We&#8217;re proud of it.  No different than an architect whose proud of a house he&#8217;s built or a chef whose proud of his food.</p>
<p>4.  Stay up-to-date<br />
I won&#8217;t harp on this long because I&#8217;ve said this before.  Programmers use what&#8217;s available to them.  I love LINQ, but I know LINQ because I read about it before it was even released publicly.  I can do a lot of stuff easier with LINQ.  I love WPF, but I know WPF because I read about it before it was even released publicly.  I can do a lot of stuff easier with WPF then I could with WinForms.  If you don&#8217;t stay current there&#8217;s a good chance you&#8217;ll jump into a project where it&#8217;s using something you don&#8217;t understand.</p>
<p>5.  Code to maintain<br />
I suppose this is really the heart of the issue.  What the hell does this mean?  Any adequate programmer should be able to jump into a piece of code and start working on bugs and adding features.  I&#8217;m not saying there won&#8217;t be a spin-up.  Of course there is going to be some spin-up.  But try and minimize that.  When most people are working on code they&#8217;re not thinking that in a year or more someone is going to have to come behind them and read the same code trying to figure out what they were doing.  But they should be.</p>
<p>Finally, I want happy clients.  That means minimizing maintenance.  There will always be maintenance, it&#8217;s inevitable.  But when I can jump into the maintenance tail of an project faster, fix bugs faster, implement new features faster than clients are happier and my job is easier.  And I like it when my job is easier.  It will always be challenging but I prefer challenging and fun to challenging and a pain in my ass.</p>
<p>I could keep going.  Someone could write a book on the subject (yeah, I know, Code Complete).  This post is just intended to hit a few top issues I&#8217;ve seen when maintaining code. YMMV.  You may have seen other issues that top this list.  Tell me about them.  Post a comment.</p>
<p>Later,<br />
Brian</p>



Share and Enjoy:


	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2010%2F02%2Fprogramming-for-maintenance%2F&amp;title=Programming%20for%20Maintenance&amp;bodytext=Code%20Complete%20defines%20Maintainability%20as%20%22The%20ease%20with%20which%20you%20can%20modify%20a%20software%20system%20to%20change%20or%20add%20capabilities%2C%20improve%20performance%2C%20or%20correct%20defects.%22%0D%0A%0D%0AI%27ve%20been%20thinking%20for%20awhile%20now%20about%20this%20post%20and%20I%27ve%20been%20unsure%20of%20exact" title="Digg"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fwww.formatexception.com%2F2010%2F02%2Fprogramming-for-maintenance%2F&amp;t=Programming%20for%20Maintenance" title="Facebook"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.dotnetkicks.com/kick/?url=http%3A%2F%2Fwww.formatexception.com%2F2010%2F02%2Fprogramming-for-maintenance%2F&amp;title=Programming%20for%20Maintenance" title="DotNetKicks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/dotnetkicks.png" title="DotNetKicks" alt="DotNetKicks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.formatexception.com%2F2010%2F02%2Fprogramming-for-maintenance%2F&amp;title=Programming%20for%20Maintenance&amp;annotation=Code%20Complete%20defines%20Maintainability%20as%20%22The%20ease%20with%20which%20you%20can%20modify%20a%20software%20system%20to%20change%20or%20add%20capabilities%2C%20improve%20performance%2C%20or%20correct%20defects.%22%0D%0A%0D%0AI%27ve%20been%20thinking%20for%20awhile%20now%20about%20this%20post%20and%20I%27ve%20been%20unsure%20of%20exact" title="Google Bookmarks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="https://favorites.live.com/quickadd.aspx?marklet=1&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2010%2F02%2Fprogramming-for-maintenance%2F&amp;title=Programming%20for%20Maintenance" title="Live"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://news.ycombinator.com/submitlink?u=http%3A%2F%2Fwww.formatexception.com%2F2010%2F02%2Fprogramming-for-maintenance%2F&amp;t=Programming%20for%20Maintenance" title="HackerNews"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/hackernews.png" title="HackerNews" alt="HackerNews" class="sociable-hovers" /></a>


<br/><br/>]]></content:encoded>
			<wfw:commentRss>http://www.formatexception.com/2010/02/programming-for-maintenance/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Book Review: Code Complete</title>
		<link>http://www.formatexception.com/2009/04/book-review-code-complete/</link>
		<comments>http://www.formatexception.com/2009/04/book-review-code-complete/#comments</comments>
		<pubDate>Wed, 15 Apr 2009 15:06:02 +0000</pubDate>
		<dc:creator>Brian</dc:creator>
				<category><![CDATA[Programming Standards]]></category>
		<category><![CDATA[Book Review]]></category>

		<guid isPermaLink="false">http://www.formatexception.com/?p=213</guid>
		<description><![CDATA[I suppose for any serious software engineer one must read Code Complete.  Last week I finished it and have been trying to think of how to write a review of it. I&#8217;ve decided to do so briefly.  
Let me start off by saying I&#8217;m excited that I finished it.  There is a [...]]]></description>
			<content:encoded><![CDATA[<p>I suppose for any serious software engineer one must read <a href="http://www.amazon.com/Code-Complete-Practical-Handbook-Construction/dp/0735619670/ref=pd_bbs_sr_1?ie=UTF8&#038;s=books&#038;qid=1239806638&#038;sr=8-1" target="_blank">Code Complete</a>.  Last week I finished it and have been trying to think of how to write a review of it. I&#8217;ve decided to do so briefly.  </p>
<p>Let me start off by saying I&#8217;m excited that I finished it.  There is a lot of good information and there is no doubt that it is the standard for sound software developement principles.  That being said, remember when you try to tackle this bood that it is a text book.  Sure there are some interesting anecdotes about this and that.  I suppose I should have been more thrilled about reading it but couldn&#8217;t drag myself to pour through it like I have some of my other software books.  It took me a year to read Code Complete.  During that time I re-read <a href="http://www.amazon.com/s/ref=nb_ss_b?url=search-alias%3Dstripbooks&#038;field-keywords=belgariad&#038;x=0&#038;y=0" target="_blank">The Belgariad series</a>, <a href="http://www.amazon.com/s/qid=1239806906/ref=a9_sc_1?ie=UTF8&#038;search-alias=stripbooks&#038;field-keywords=malloreon" target="_blank">The Malloreon series</a>, most of the <a href="http://www.amazon.com/s/ref=nb_ss_b?url=search-alias%3Dstripbooks&#038;field-keywords=song+of+ice+and+fire&#038;x=0&#038;y=0" target="_blank">Song of Ice and Fire series</a>, and read for the first time <a href="http://www.amazon.com/Pro-WPF-2008-Presentation-Professionals/dp/1590599551/ref=sr_1_1?ie=UTF8&#038;s=books&#038;qid=1239807040&#038;sr=1-1" target="_blank">Pro WPF in C# 2008</a>, <a href="http://www.amazon.com/Effective-Specific-Improve-Software-Development/dp/0321245660/ref=sr_1_2?ie=UTF8&#038;s=books&#038;qid=1239807085&#038;sr=1-2" target="_blank">Effective C#</a> and I&#8217;m almost done with <a href="http://www.amazon.com/More-Effective-Specific-Software-Development/dp/0321485890/ref=sr_1_1?ie=UTF8&#038;s=books&#038;qid=1239807085&#038;sr=1-1" target="_blank">More Effective C#</a>.</p>
<p>So what am I saying?  I know there are those of you out there that love Code Complete and read it voraciously like a good fiction novel.  I couldn&#8217;t even read it like a good code book.  Pro WPF in C# 2008 I read like a good fiction novel.  I drank it in and loved it.  Code Complete I just couldn&#8217;t do that with.  As I said, it&#8217;s sound, solid developement principles I try to apply every day on the job.  I learned a lot and will continue to try and apply the princibles of Code Complete.  Simply because of that it is a reason to read the book.</p>
<p>If you&#8217;re like me and are struggling to get through Code Complete, spread it out, read a chapter and then take a break and read something else.  There are 35 chapters in Code Complete.  Read a chapter every two weeks, in between other books and it will take you just a bit over a year to read it.</p>
<p>What else can I say?  99% of the book makes perfect sense.  Some of the code formatting seemed a bit off but I just let visual studio format my code for me.  Ctrl-K + Ctrl-D, Baby!</p>
<p>Read it, grok it, follow it and your code will be better, cleaner and easier to maintain.<br />
That&#8217;s all there it to it.</p>
<p>Brian</p>



Share and Enjoy:


	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2009%2F04%2Fbook-review-code-complete%2F&amp;title=Book%20Review%3A%20Code%20Complete&amp;bodytext=%0D%0A%0D%0AI%20suppose%20for%20any%20serious%20software%20engineer%20one%20must%20read%20Code%20Complete.%20%20Last%20week%20I%20finished%20it%20and%20have%20been%20trying%20to%20think%20of%20how%20to%20write%20a%20review%20of%20it.%20I%27ve%20decided%20to%20do%20so%20briefly.%20%20%0D%0A%0D%0ALet%20me%20start%20off%20by%20saying%20I%27m%20excited%20that%20I%20fini" title="Digg"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fwww.formatexception.com%2F2009%2F04%2Fbook-review-code-complete%2F&amp;t=Book%20Review%3A%20Code%20Complete" title="Facebook"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.dotnetkicks.com/kick/?url=http%3A%2F%2Fwww.formatexception.com%2F2009%2F04%2Fbook-review-code-complete%2F&amp;title=Book%20Review%3A%20Code%20Complete" title="DotNetKicks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/dotnetkicks.png" title="DotNetKicks" alt="DotNetKicks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.formatexception.com%2F2009%2F04%2Fbook-review-code-complete%2F&amp;title=Book%20Review%3A%20Code%20Complete&amp;annotation=%0D%0A%0D%0AI%20suppose%20for%20any%20serious%20software%20engineer%20one%20must%20read%20Code%20Complete.%20%20Last%20week%20I%20finished%20it%20and%20have%20been%20trying%20to%20think%20of%20how%20to%20write%20a%20review%20of%20it.%20I%27ve%20decided%20to%20do%20so%20briefly.%20%20%0D%0A%0D%0ALet%20me%20start%20off%20by%20saying%20I%27m%20excited%20that%20I%20fini" title="Google Bookmarks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="https://favorites.live.com/quickadd.aspx?marklet=1&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2009%2F04%2Fbook-review-code-complete%2F&amp;title=Book%20Review%3A%20Code%20Complete" title="Live"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://news.ycombinator.com/submitlink?u=http%3A%2F%2Fwww.formatexception.com%2F2009%2F04%2Fbook-review-code-complete%2F&amp;t=Book%20Review%3A%20Code%20Complete" title="HackerNews"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/hackernews.png" title="HackerNews" alt="HackerNews" class="sociable-hovers" /></a>


<br/><br/>]]></content:encoded>
			<wfw:commentRss>http://www.formatexception.com/2009/04/book-review-code-complete/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Top 25 Most Dangerous Programming Errors</title>
		<link>http://www.formatexception.com/2009/01/top-25-most-dangerous-programming-errors/</link>
		<comments>http://www.formatexception.com/2009/01/top-25-most-dangerous-programming-errors/#comments</comments>
		<pubDate>Tue, 13 Jan 2009 15:01:07 +0000</pubDate>
		<dc:creator>Brian</dc:creator>
				<category><![CDATA[Programming Standards]]></category>

		<guid isPermaLink="false">http://www.formatexception.com/?p=155</guid>
		<description><![CDATA[Follow the below link, read it, consume it, grok it.
2009 CWE/SANS Top 25 Most Dangerous Programming Errors (If it doesn&#8217;t come up be patient.  It looks like the server is getting hit pretty hard with bloggers like myself linking to it.)
Or read a summary of it and then go to the link over at [...]]]></description>
			<content:encoded><![CDATA[<p>Follow the below link, read it, consume it, grok it.</p>
<p><a href="http://cwe.mitre.org/top25/#Brief" target="_blank">2009 CWE/SANS Top 25 Most Dangerous Programming Errors</a> (If it doesn&#8217;t come up be patient.  It looks like the server is getting hit pretty hard with bloggers like myself linking to it.)</p>
<p>Or read <a href="http://www.codinghorror.com/blog/archives/001210.html" target="_blank">a summary of it</a> and then go to the link over at <a href="http://www.codinghorror.com" target="_blank">Coding Horror</a>.</p>
<p>On a side note, now that the holidays have calmed down I&#8217;ve been working on a series of &#8220;Often Unused Operators&#8221; like ~ and |=.  Credit goes to <a href="http://www.cowgod.net" target="_blank">Jeff Clark</a> for turning me onto this.  Hopefully I&#8217;ll have the first one up on Friday.</p>
<p>Brian</p>



Share and Enjoy:


	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2009%2F01%2Ftop-25-most-dangerous-programming-errors%2F&amp;title=Top%2025%20Most%20Dangerous%20Programming%20Errors&amp;bodytext=Follow%20the%20below%20link%2C%20read%20it%2C%20consume%20it%2C%20grok%20it.%0D%0A%0D%0A2009%20CWE%2FSANS%20Top%2025%20Most%20Dangerous%20Programming%20Errors%20%28If%20it%20doesn%27t%20come%20up%20be%20patient.%20%20It%20looks%20like%20the%20server%20is%20getting%20hit%20pretty%20hard%20with%20bloggers%20like%20myself%20linking%20to%20it.%29%0D%0A%0D%0AOr%20rea" title="Digg"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fwww.formatexception.com%2F2009%2F01%2Ftop-25-most-dangerous-programming-errors%2F&amp;t=Top%2025%20Most%20Dangerous%20Programming%20Errors" title="Facebook"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.dotnetkicks.com/kick/?url=http%3A%2F%2Fwww.formatexception.com%2F2009%2F01%2Ftop-25-most-dangerous-programming-errors%2F&amp;title=Top%2025%20Most%20Dangerous%20Programming%20Errors" title="DotNetKicks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/dotnetkicks.png" title="DotNetKicks" alt="DotNetKicks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.formatexception.com%2F2009%2F01%2Ftop-25-most-dangerous-programming-errors%2F&amp;title=Top%2025%20Most%20Dangerous%20Programming%20Errors&amp;annotation=Follow%20the%20below%20link%2C%20read%20it%2C%20consume%20it%2C%20grok%20it.%0D%0A%0D%0A2009%20CWE%2FSANS%20Top%2025%20Most%20Dangerous%20Programming%20Errors%20%28If%20it%20doesn%27t%20come%20up%20be%20patient.%20%20It%20looks%20like%20the%20server%20is%20getting%20hit%20pretty%20hard%20with%20bloggers%20like%20myself%20linking%20to%20it.%29%0D%0A%0D%0AOr%20rea" title="Google Bookmarks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="https://favorites.live.com/quickadd.aspx?marklet=1&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2009%2F01%2Ftop-25-most-dangerous-programming-errors%2F&amp;title=Top%2025%20Most%20Dangerous%20Programming%20Errors" title="Live"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://news.ycombinator.com/submitlink?u=http%3A%2F%2Fwww.formatexception.com%2F2009%2F01%2Ftop-25-most-dangerous-programming-errors%2F&amp;t=Top%2025%20Most%20Dangerous%20Programming%20Errors" title="HackerNews"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/hackernews.png" title="HackerNews" alt="HackerNews" class="sociable-hovers" /></a>


<br/><br/>]]></content:encoded>
			<wfw:commentRss>http://www.formatexception.com/2009/01/top-25-most-dangerous-programming-errors/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Making Classes and Properties Immutable</title>
		<link>http://www.formatexception.com/2008/12/making-classes-and-properties-immutable/</link>
		<comments>http://www.formatexception.com/2008/12/making-classes-and-properties-immutable/#comments</comments>
		<pubDate>Mon, 01 Dec 2008 17:43:27 +0000</pubDate>
		<dc:creator>Brian</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Programming Standards]]></category>
		<category><![CDATA[immutable]]></category>
		<category><![CDATA[property]]></category>

		<guid isPermaLink="false">http://www.formatexception.com/?p=141</guid>
		<description><![CDATA[Hopefully we all know string is immutable.  When you type:
string x = "";
x = "asdf";
what you are really doing is creating two different strings, not changing the value, per se, of x but actually creating a new x.
That is why in heavy string opperations it is recommended you use StringBuilder like:
StringBuilder sbName = new [...]]]></description>
			<content:encoded><![CDATA[<p>Hopefully we all know string is immutable.  When you type:</p>
<pre name="code" class="csharp">string x = "";
x = "asdf";</pre>
<p>what you are really doing is creating two different strings, not changing the value, per se, of x but actually creating a new x.<br />
That is why in heavy string opperations it is recommended you use StringBuilder like:</p>
<pre name="code" class="csharp">StringBuilder sbName = new StringBuilder();
sbName.Append("asdf");</pre>
<p> since appending to sbName doesn&#8217;t create a new string but continues to add to the string value of sbName.</p>
<p>So why do you care?  Well, maybe you don&#8217;t.  I&#8217;ve started to move into a more multi-threaded world where the state of objects and their properties could potientially be invalid if an external thread changes the value of a property.  I&#8217;ve been reading <a href="http://www.amazon.com/Effective-Specific-Improve-Software-Development/dp/0321245660/ref=pd_bbs_sr_2?ie=UTF8&#038;s=books&#038;qid=1228149965&#038;sr=8-2" target="_blank">Effective C#</a> and <a href="http://www.amazon.com/More-Effective-Specific-Software-Development/dp/0321485890/ref=pd_bbs_sr_1?ie=UTF8&#038;s=books&#038;qid=1228149965&#038;sr=8-1" target="_blank">More Effective C#</a> and enjoying them.  They are books that target specific development issues and paradigms that help you become a better C# developer.  The books are written by <a href="http://srtsolutions.com/blogs/billwagner/" target="_blank">Bill Wagner</a> who is a regular blogger I follow.  </p>
<p>Even though Effective C# came out in the .NET 2.0 days alot of the book is still relevant, however, quite a few of the code samples could be updated.  </p>
<p>Item 7 in Effective C# says &#8220;Prefer Immutable Atomic Value Types&#8221;.  Now to paraphrase the chapter to an extreme it basically says, &#8220;Immutable code is easier to maintain&#8221;.  I would add an addendum that whether you like it or not there is a good chance that code you write will be used in a multi-threaded environment and immutable will matter.  </p>
<p>Now obviously to blindly say all classes must be like this is absurd.  As Bill&#8217;s Item 7 says, however, &#8220;Prefer Immutable Atomic Value Types&#8221;.</p>
<p>In .NET 3.0 properties made things a bit easier in general.  Prior to 3.0 for a property you would have to do:</p>
<pre name="code" class="csharp">private int _myInt;
public int MyInt
{
    get { return _myInt; }
    set { _myInt = value; }
}</pre>
<p>In .NET 3.0 you don&#8217;t have to define the private.  When the code is compiled it will take care of that for you. So the above code becomes:</p>
<pre name="code" class="csharp">public int MyInt { get; set; }</pre>
<p>Now say you have to class:</p>
<pre name="code" class="csharp">public class Customer
{
    public string FirstName { get; set; }
    public string LastName { get; set; }
    public Address Address { get; set; }
    public Customer(){}
}</pre>
<p>If you were working in a multi-threaded environment you might have a problem if this happens:</p>
<pre name="code" class="csharp">public void HandleCustomerData(Customer MyCustomer)
{
    MyCustomer.FirstName = "George";

    //use myCustomer to do a bunch of stuff

    MyCustomer.FirstName = "Joe";

    //use myCustomer to do a bunch of stuff
}</pre>
<p>This could cause a big problem if MyCustomer is getting passed around alot in different threads.  Now I know this is rather contrived but it is still a real issue.</p>
<p>Properties an additional feature here in 3.0 that makes things easier for creating an immutable.  Imagine you have to class:</p>
<pre name="code" class="csharp">public class Customer
{
    public string FirstName { get; private set; }
    public string LastName { get; private set; }
    public Address Address { get; private set; }
    public Customer(string FirstName, string LastName, Address Address)
    {
        this.FirstName = FirstName;
        this.LastName = LastName;
        this.Address = Address;
    }
}</pre>
<p>You can see here that I&#8217;m using the private keyword on the set method.  As it implies this forces the set methods of the properties to private so they can only be changed internally in the class.  I would recommend reading &#8220;Effective C#&#8221; for a better explanation of why to use immutable values but by using the private in a property this becomes easier.</p>
<p>So there it is, prefer immutable atomic values in your classes and use the private keyword to help you.</p>
<p>Later,<br />
Brian</p>
<p><strong>Update:</strong><br />
The more I read this the more I think I over-simplified Bill&#8217;s reason for prefering immutable atomic value types.  Just get the book and read it.  It&#8217;s a fairly small book but every nugget has value.</p>



Share and Enjoy:


	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2008%2F12%2Fmaking-classes-and-properties-immutable%2F&amp;title=Making%20Classes%20and%20Properties%20Immutable&amp;bodytext=Hopefully%20we%20all%20know%20string%20is%20immutable.%20%20When%20you%20type%3A%0D%0Astring%20x%20%3D%20%22%22%3B%0D%0Ax%20%3D%20%22asdf%22%3B%0D%0Awhat%20you%20are%20really%20doing%20is%20creating%20two%20different%20strings%2C%20not%20changing%20the%20value%2C%20per%20se%2C%20of%20x%20but%20actually%20creating%20a%20new%20x.%20%20%0D%0AThat%20is%20why%20in%20heavy%20string%20o" title="Digg"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fwww.formatexception.com%2F2008%2F12%2Fmaking-classes-and-properties-immutable%2F&amp;t=Making%20Classes%20and%20Properties%20Immutable" title="Facebook"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.dotnetkicks.com/kick/?url=http%3A%2F%2Fwww.formatexception.com%2F2008%2F12%2Fmaking-classes-and-properties-immutable%2F&amp;title=Making%20Classes%20and%20Properties%20Immutable" title="DotNetKicks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/dotnetkicks.png" title="DotNetKicks" alt="DotNetKicks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.formatexception.com%2F2008%2F12%2Fmaking-classes-and-properties-immutable%2F&amp;title=Making%20Classes%20and%20Properties%20Immutable&amp;annotation=Hopefully%20we%20all%20know%20string%20is%20immutable.%20%20When%20you%20type%3A%0D%0Astring%20x%20%3D%20%22%22%3B%0D%0Ax%20%3D%20%22asdf%22%3B%0D%0Awhat%20you%20are%20really%20doing%20is%20creating%20two%20different%20strings%2C%20not%20changing%20the%20value%2C%20per%20se%2C%20of%20x%20but%20actually%20creating%20a%20new%20x.%20%20%0D%0AThat%20is%20why%20in%20heavy%20string%20o" title="Google Bookmarks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="https://favorites.live.com/quickadd.aspx?marklet=1&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2008%2F12%2Fmaking-classes-and-properties-immutable%2F&amp;title=Making%20Classes%20and%20Properties%20Immutable" title="Live"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://news.ycombinator.com/submitlink?u=http%3A%2F%2Fwww.formatexception.com%2F2008%2F12%2Fmaking-classes-and-properties-immutable%2F&amp;t=Making%20Classes%20and%20Properties%20Immutable" title="HackerNews"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/hackernews.png" title="HackerNews" alt="HackerNews" class="sociable-hovers" /></a>


<br/><br/>]]></content:encoded>
			<wfw:commentRss>http://www.formatexception.com/2008/12/making-classes-and-properties-immutable/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Assert Yourself!</title>
		<link>http://www.formatexception.com/2008/09/assert-yourself/</link>
		<comments>http://www.formatexception.com/2008/09/assert-yourself/#comments</comments>
		<pubDate>Mon, 29 Sep 2008 16:28:49 +0000</pubDate>
		<dc:creator>Brian</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Programming Standards]]></category>
		<category><![CDATA[Assert]]></category>

		<guid isPermaLink="false">http://www.formatexception.com/?p=74</guid>
		<description><![CDATA[Java folks, please don&#8217;t get scared off by the C# examples, the contents of the post apply regardless if it is java or C#.
None of us use Asserts enough. It&#8217;s that simple, we don&#8217;t. Asserts are essentially a way to ensure we don&#8217;t get a value we shouldn&#8217;t have. The great thing about using asserts [...]]]></description>
			<content:encoded><![CDATA[<p>Java folks, please don&#8217;t get scared off by the C# examples, the contents of the post apply regardless if it is java or C#.</p>
<p>None of us use Asserts enough. It&#8217;s that simple, we don&#8217;t. Asserts are essentially a way to ensure we don&#8217;t get a value we shouldn&#8217;t have. The great thing about using asserts is that they aren&#8217;t included in final code (compiled in &#8220;Release&#8221;), only code complied with &#8220;Debug&#8221;. They make testing easier by verifying that when code is being tested in Debug that it doesn&#8217;t go beyond some condition. They can also be used to ensure when troubleshooting that you have the values you should.</p>
<p>Take a look at the code below:</p>
<pre name="code" class="C#">
private void pass_Click(object sender, RoutedEventArgs e)
{
    int temp = 1;
    Debug.Assert(temp > 0);
    MessageBox.Show(“Pass”);
}

private void fail_Click(object sender, RoutedEventArgs e)
{
    int temp = -1;
    Debug.Assert(temp > 0);
    MessageBox.Show(“Fail”);
}
</pre>
<p>This is a sample of using an assert. I know the example is trivial but I wanted to show a simple use of it. These are simply a Click event on a &#8220;Pass&#8221; button and a Click event on a &#8220;Fail&#8221; button. I would recommend you create your own solution and put these on a pass and fail button so you can see and understand what happens when Debug.Assert is called.</p>
<p>Now lately I&#8217;ve been coming across a lot of code like (anonymous-ized for your protection):</p>
<div style="font-family:Monospace; font-size: 10pt; background-color: white;"><span style="color: #0000ff;">else<br />
</span><span style="color: #000000;">{<br />
</span><span style="color: #2b91af;">    MessageBox</span><span style="color: #000000;">.Show(</span><span style="color: #a31515;">&#8220;ERROR: YOU SHOULD NEVER SEE THIS MESSAGE.  Invalid TransformString!&#8221;</span><span style="color: #000000;">, </span><span style="color: #a31515;">&#8220;SERIOUS ERROR occurred in MyClass:MyMethod&#8221;</span><span style="color: #000000;">, </span><span style="color: #2b91af;">MessageBoxButton</span><span style="color: #000000;">.OK, </span><span style="color: #2b91af;">MessageBoxImage</span><span style="color: #000000;">.Error);<br />
}</span></div>
<p>I&#8217;m sorry but this is simply wrong.</p>
<p>Code Complete 2nd edition has a great chapter on Assertions. The above example is exactly where asserts should be used.</p>
<p>Per the guidelines for &#8220;Using Assertions&#8221; (McConnnel, Code Complete 2, 2004) the following guidelines should apply for using assertions:</p>
<p>&#8220;Use error-handling code for conditions you expect to occur; use assertions for conditions that should never occur.</p>
<p>Avoid putting executable code into assertions.</p>
<p>Use assertions to document and verify preconditions and post conditions.</p>
<p>For highly robust code, assert and then handle the error anyway.&#8221;</p>
<p>That&#8217;s right. The very first usage guideline says to use asserts for conditions that should never occur.</p>
<p>Take a look at a sample from Code Complete (originally VB but I ported it to C#):</p>
<div style="font-family:Monospace; font-size: 10pt; background-color: white;"><span style="color: #0000ff;">private</span><span style="color: #000000;"> </span><span style="color: #0000ff;">double</span><span style="color: #000000;"> Velocity(</span><span style="color: #0000ff;">double</span><span style="color: #000000;"> Latitude, </span><span style="color: #0000ff;">double</span><span style="color: #000000;"> Longitude, </span><span style="color: #0000ff;">double</span><span style="color: #000000;"> Elevation)<br />
{<br />
</span><span style="color: #008000;">    //Verify preconditions<br />
</span><span style="color: #000000;">    </span><span style="color: #2b91af;">Debug</span><span style="color: #000000;">.Assert(Latitude &gt;= -90 &amp;&amp; Latitude &lt;= 90, </span><span style="color: #a31515;">&#8220;Invalid Latitude&#8221;</span><span style="color: #000000;">);<br />
    </span><span style="color: #2b91af;">Debug</span><span style="color: #000000;">.Assert(Longitude &gt;= 0 &amp;&amp; Longitude &lt;= 360, </span><span style="color: #a31515;">&#8220;Invalid Longitude&#8221;</span><span style="color: #000000;">);<br />
    </span><span style="color: #2b91af;">Debug</span><span style="color: #000000;">.Assert(Elevation &gt;= -500 &amp;&amp; Elevation &lt;= 75000, </span><span style="color: #a31515;">&#8220;Invalid Elevation&#8221;</span><span style="color: #000000;">);<br />
    </span></div>
<div style="font-family:Monospace; font-size: 10pt; background-color: white;">    <span style="color: #0000ff;">double</span><span style="color: #000000;"> velocity = 0;<br />
    </span><span style="color: #008000;">/* DO THE WORK */<span style="color: #000000;">    </span><span style="color: #008000;">//Verify postconditions<br />
</span><span style="color: #000000;">    </span><span style="color: #2b91af;">Debug</span><span style="color: #000000;">.Assert(velocity &gt;= 0 &amp;&amp; velocity &lt;= 600, <br />
                 </span><span style="color: #a31515;">&#8220;Invalid Velocity&#8221;</span><span style="color: #000000;">, <br />
                 </span><span style="color: #a31515;">&#8220;Can&#8217;t seem to properly work the velocity formula&#8221;</span><span style="color: #000000;">);<br />
    </span><span style="color: #0000ff;">return</span><span style="color: #000000;"> velocity;<br />
}</span></p>
<p></span></div>
<p>On this McConnell has to say:<br />
&#8220;If the variables Latitude, Longitude, and Elevation were coming from an external source, invalid values should be checked and handled by error-handling code rather then by assertions. If the variables are coming from a trusted, internal source, however, and the routine&#8217;s design is based on the assumption that these values will be withn their valid ranges, then assertions are appropriate.&#8221; (McConnell, 2004)</p>
<p>Now assertions aren&#8217;t the end-all, be-all of validating values. Chances are that in most cases you are still going to want to validate and do error checking. But they&#8217;re a good start.</p>
<p>And just for the java folks that hung around, an assert in java:</p>
<div style="font-family:Monospace; font-size: 10pt; background-color: white;"><span style="color: #008000;">//Check to make sure we&#8217;re not going to do a divide by zero<br />
</span><span style="color: #000000;">assert denominator != 0: </span><span style="color: #a31515;">&#8220;denominator is 0&#8243;</span><span style="color: #000000;">;</span></div>
<p>Refs:</p>
<p>Code Complete (Second Edition), Microsoft Press, Steve McConnell, 2004</p>
<p><a href="http://en.csharp-online.net/Assert" target="_blank">C# Online.NET &#8211; Assert</a></p>
<p><a href="http://msdn.microsoft.com/en-us/library/system.diagnostics.debug.assert.aspx" target="_blank">Debug.Assert Method</a></p>
<p>And just for the java folks:<br />
<a href="http://java.sun.com/j2se/1.4.2/docs/guide/lang/assert.html" target="_blank">Programming With Assertions</a></p>



Share and Enjoy:


	<a rel="nofollow"  target="_blank" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2008%2F09%2Fassert-yourself%2F&amp;title=Assert%20Yourself%21&amp;bodytext=Java%20folks%2C%20please%20don%27t%20get%20scared%20off%20by%20the%20C%23%20examples%2C%20the%20contents%20of%20the%20post%20apply%20regardless%20if%20it%20is%20java%20or%20C%23.%0D%0A%0D%0ANone%20of%20us%20use%20Asserts%20enough.%20It%27s%20that%20simple%2C%20we%20don%27t.%20Asserts%20are%20essentially%20a%20way%20to%20ensure%20we%20don%27t%20get%20a%20value%20we%20s" title="Digg"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/digg.png" title="Digg" alt="Digg" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.facebook.com/share.php?u=http%3A%2F%2Fwww.formatexception.com%2F2008%2F09%2Fassert-yourself%2F&amp;t=Assert%20Yourself%21" title="Facebook"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/facebook.png" title="Facebook" alt="Facebook" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.dotnetkicks.com/kick/?url=http%3A%2F%2Fwww.formatexception.com%2F2008%2F09%2Fassert-yourself%2F&amp;title=Assert%20Yourself%21" title="DotNetKicks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/dotnetkicks.png" title="DotNetKicks" alt="DotNetKicks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://www.google.com/bookmarks/mark?op=edit&amp;bkmk=http%3A%2F%2Fwww.formatexception.com%2F2008%2F09%2Fassert-yourself%2F&amp;title=Assert%20Yourself%21&amp;annotation=Java%20folks%2C%20please%20don%27t%20get%20scared%20off%20by%20the%20C%23%20examples%2C%20the%20contents%20of%20the%20post%20apply%20regardless%20if%20it%20is%20java%20or%20C%23.%0D%0A%0D%0ANone%20of%20us%20use%20Asserts%20enough.%20It%27s%20that%20simple%2C%20we%20don%27t.%20Asserts%20are%20essentially%20a%20way%20to%20ensure%20we%20don%27t%20get%20a%20value%20we%20s" title="Google Bookmarks"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/googlebookmark.png" title="Google Bookmarks" alt="Google Bookmarks" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="https://favorites.live.com/quickadd.aspx?marklet=1&amp;url=http%3A%2F%2Fwww.formatexception.com%2F2008%2F09%2Fassert-yourself%2F&amp;title=Assert%20Yourself%21" title="Live"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/live.png" title="Live" alt="Live" class="sociable-hovers" /></a>
	<a rel="nofollow"  target="_blank" href="http://news.ycombinator.com/submitlink?u=http%3A%2F%2Fwww.formatexception.com%2F2008%2F09%2Fassert-yourself%2F&amp;t=Assert%20Yourself%21" title="HackerNews"><img src="http://www.formatexception.com/wp-content/plugins/sociable/images/hackernews.png" title="HackerNews" alt="HackerNews" class="sociable-hovers" /></a>


<br/><br/>]]></content:encoded>
			<wfw:commentRss>http://www.formatexception.com/2008/09/assert-yourself/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
