<?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>while coding &#187; essays</title>
	<atom:link href="http://www.youell.com/matt/writing/?cat=28&#038;feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.youell.com/matt/writing</link>
	<description>simplify</description>
	<lastBuildDate>Wed, 31 Oct 2018 04:08:22 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>A Note on Hate Crimes</title>
		<link>http://www.youell.com/matt/writing/?p=494</link>
		<comments>http://www.youell.com/matt/writing/?p=494#comments</comments>
		<pubDate>Wed, 05 Aug 2009 13:46:11 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[essays]]></category>
		<category><![CDATA[politics]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=494</guid>
		<description><![CDATA[I don&#8217;t talk politics here very often. I tend to focus on programming and related things. But the name of the blog is &#8220;While Coding&#8221; for a reason: I blog almost exclusively about things that pop into my head when I&#8217;m trying to get some code written. Blogging frees my brain cells so I can [...]]]></description>
			<content:encoded><![CDATA[<p>I don&#8217;t talk politics here very often. I tend to focus on programming and related things. But the name of the blog is &#8220;While Coding&#8221; for a reason: I blog almost exclusively about things that pop into my head when I&#8217;m trying to get some code written. Blogging frees my brain cells so I can work. Lately I&#8217;ve been able to let off a lot of that steam through Twitter (much to the chagrin of those who follow me), but every now and then there is a topic that demands more than 140 characters of discussion.</p>
<p>At the library yesterday I ran into a petitioner. &#8220;Got a moment for gay rights?&#8221;, she asked. That isn&#8217;t one of my pet topics but certainly rights &#8211; gay or otherwise &#8211; are pretty important. I stopped to find out what she wanted. It turned out that she wanted support for a bill adding gays and lesbians to existing hate crimes legislation. I knew right then I wasn&#8217;t going to sign anything.</p>
<p>This had nothing to do with gay rights in my mind. From her point of view it was unfair that gays weren&#8217;t a part of the existing legislation. I agree, that&#8217;s not fair. Unfortunately, hate crimes legislation is a really bad idea to begin with. Adding more classes of people on to bad legislation only makes a bad law worse.</p>
<p>There are two fundamental problems with the idea of hate crimes: For starters, hate crimes really boil down to thought-crime. How do you get inside someone&#8217;s head and prove what they were thinking? I asked the petitioner about this. This was a question that she had a stock answer for, and she said that you train law enforcement to be able to recognize hate crimes. You might imagine that her argument didn&#8217;t win me over. </p>
<p>The greater problem with hate crimes legislation is that it takes away equal protection under the law. Hate crimes laws may start off protecting one or two classes of people, but over time more and more classes of people will be added. You start with an ethnic or religious protection, then it&#8217;s nationality, sexuality, age, gender identity, or just gender. Pretty soon the people not protected by the legislation are in the minority. Once that happens you have created a default class of people who are easier to abuse. </p>
<p>This is similar to why criminal organizations have juveniles commit crimes for them. The punishment is often less for a teenager to commit a crime than for an adult. The same will eventually happen here. It will become no big deal to commit a crime against a certain segment of the population because the punishment will be far less than for crimes against the protected classes.</p>
<p>You don&#8217;t solve bias and discrimination with more bias and discrimination.</p>
<hr />
<em>I should mention as an aside that I really admire people who get out and do the footwork for the things they believe in. This young lady at the library was obviously doing something she really believed in and was trying to make a difference. I wish there were more people out there like that. I also wish that I had stayed more politically active beyond my youth.</em></p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=494</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Secret</title>
		<link>http://www.youell.com/matt/writing/?p=314</link>
		<comments>http://www.youell.com/matt/writing/?p=314#comments</comments>
		<pubDate>Sat, 25 Apr 2009 04:05:38 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[essays]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software industry]]></category>
		<category><![CDATA[success]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=314</guid>
		<description><![CDATA[I have an amazing, incredible, mind-altering secret of incalculable value to share with you. This is a little tidbit they didn&#8217;t teach you in your CS, SE, or PM classes in college. Once you are clear about this one thing your software &#8211; and your life &#8211; will change FOREVER. I promise.
So. Would you like [...]]]></description>
			<content:encoded><![CDATA[<p>I have an amazing, incredible, mind-altering secret of incalculable value to share with you. This is a little tidbit they didn&#8217;t teach you in your CS, SE, or PM classes in college. Once you are clear about this one thing your software &#8211; and your life &#8211; will change FOREVER. I promise.</p>
<p>So. Would you like to know the single most important thing there is to know about developing software? </p>
<p>Are you ready? </p>
<p>Can you handle it??? Here it is, BAM!!!: </p>
<blockquote><p>Manage Expectations</p></blockquote>
<p>[Matt drops mic and walks off the stage.]</p>
<p>Um&#8230; that&#8217;s it. That is the whole thing, right there.</p>
<p>If you&#8217;re disappointed right now it is probably because I didn&#8217;t manage your expectations very well.</p>
<p>It&#8217;s true though. Managing expectations is more important in software than gathering requirements, analyzing problems, writing gleaming code, or shipping a high quality piece of software out the door. Those are all very important things. They just aren&#8217;t THE most important thing. </p>
<p>For years I&#8217;ve said that given the right circumstances I could succeed as a programmer without ever writing a single line of code, just by managing expectations. A couple of years ago I saw a programmer prove this, albeit in a rather unfortunate way. This guy was on the job for three months and hadn&#8217;t written a single line of code. And then he got fired. But he wasn&#8217;t fired for his code. He was fired due to office politics and teamwork problems. In fact, it was only discovered that he hadn&#8217;t written any code the day after he left! The best part is that before he was fired, <strong>he was being considered for a promotion to team lead!!!</strong></p>
<p>Did you see the video making the rounds last week about Susan Boyle, the frumpy 47 year old lady that blew away Simon Cowell with her singing? If you haven&#8217;t seen the video, <a href="http://www.youtube.com/watch?v=9lp0IWv8QZY">Go take a look</a>.  (Ordinarily I would embed the video but the fine folks at Youtube and/or BBC have disabled embedding on this one.) </p>
<p>Yes, Susan sings well. Hardly the point though. The real point is that the producers are smart! They have totally and completely <em>managed expectations</em>. Think about the entire set up: The first thing you see is a middle aged frump shoving a snack into her mouth. Then she talks and every word is in a charming but distracting brrrrrogue. And then mix in some well-timed editing: Simon&#8217;s unamused reaction when she walks up. The extreme-eye-rolling girl in the audience. Raised eyebrows everywhere. Finally, toss on some ham from the lady herself and you have a perfect recipe for a managed expectation. No one is going to watch all of those social cues and genuinely expect the lady to be able to sing a note. So when she can sing and <em>sing well</em>, POW, they got you. TV producers FTW.</p>
<p>You may think all I am describing is manipulation. That is not the case. Managing expectations is about empathy as much as it is about control. If you promise a feature in a new release of software and it isn&#8217;t there, that is going to be very disappointing for your stakeholders. And if you promise to ship a new version in a month and it takes you six months, that might put your stakeholders out of business if the project is critical enough. On the other hand, if you promise something in six months and it takes you four, you&#8217;ve got a couple of months to catch any problems you may have missed and you can ship early.</p>
<p>It is far, far better to manage expectations &#8211; including your own &#8211; and produce average results, than it is to try to produce outstanding results without managing anyone&#8217;s expectations. And many times &#8211; when you manage expectations well &#8211; your &#8220;average results&#8221; turn out to be quite above average.<br />
<center><br />
<div id="attachment_348" class="wp-caption center" style="width: 410px"><a href="http://www.flickr.com/photos/sea-turtle/2861575686/"><img src="http://www.youell.com/matt/writing/wp-content/uploads/2009/04/expectations.jpg" alt="Photo courtesy of Sea Turtle" title="expectations" width="400" height="320" class="size-full wp-image-348" /></a><p class="wp-caption-text">Photo courtesy of Sea Turtle</p></div></center></p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=314</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My Kung Fu is the Best</title>
		<link>http://www.youell.com/matt/writing/?p=166</link>
		<comments>http://www.youell.com/matt/writing/?p=166#comments</comments>
		<pubDate>Wed, 04 Feb 2009 22:52:38 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[essays]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[rants]]></category>
		<category><![CDATA[software industry]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=166</guid>
		<description><![CDATA[I don&#8217;t know if it is a phase I&#8217;m going through or if I&#8217;m just starting to show my age, but I&#8217;m growing tired of meta. I spend so much time learning new things about programming that the amount of code I&#8217;m actually generating has deteriorated down to just what I&#8217;m doing for work. 
I [...]]]></description>
			<content:encoded><![CDATA[<p>I don&#8217;t know if it is a phase I&#8217;m going through or if I&#8217;m just starting to show my age, but I&#8217;m growing tired of meta. I spend so much time learning new things about programming that the amount of code I&#8217;m actually generating has deteriorated down to just what I&#8217;m doing for work. </p>
<p>I didn&#8217;t come to programming from Computer Science. I was an Electrical Engineering major who switched over to Physics and then fell into programming as a hobby which turned into a career. When I first started programming I had a very low opinion of it. I see a lot of EE types with this attitude: software is easy, and what <em>they</em> do is the hard stuff. Even back then I could see that the field of programming was a huge mental quagmire and I swore that I would not get caught up in it. Software is just there to make the hardware do stuff. My attitude was that the &#8220;how&#8221; doesn&#8217;t matter so much as long as it works.</p>
<p>Naturally that&#8217;s not what happened. I got swept up in the industry trends. I became addicted to learning what was new and cool. I was an object zealot and fanboy. Then STL. Scripting languages. ORM. Patterns. TDD. Refactoring. The past few years it&#8217;s been functional and logic programming. And that&#8217;s all great. I&#8217;ve learned a lot and had a lot of fun. But sometimes I wonder if I had just kept my head down and coded more instead of trending more, where I would be. I&#8217;m not talking about ignorance here, just pragmatism. There is a balance between the two and I wonder how far off the mark I am, or if I&#8217;m off the mark at all.</p>
<p>What I&#8217;m growing increasingly intolerant of is zealotry and opinionism. Both of which are almost inseparable from computer programmers. The worst is when I feel it from within. When someone shit-talks the tools I use to do my job, I get a little tight in the chest. And why? Why the hell should I? If I&#8217;m getting my work done the best way I know how and the people who use my software are happy, then what is the problem? The truth is, there isn&#8217;t a problem.</p>
<p>Michelangelo is said to have seen sculpting not as chiseling out an image from stone, but as releasing the sculpture that was already in the stone. That is such a powerful idea because it means that there are an unlimited number of sculptures in that stone. No two sculptors would set the same sculpture free. Programming is like that. Software is so very abstract, and the limitations on what we do are relatively few compared to other disciplines. Anything that works and makes sense to the programmer is probably not wrong in a fundamental sense. Certainly issues of specific application, maintenance and communication can be discussed, but what I&#8217;m getting at is that my methodology or toolset is not dumb just because it isn&#8217;t the one you use.</p>
<p>&#8220;The Tao that can be told is not the eternal Tao.&#8221; </p>
<p>That&#8217;s a nice way of saying that you do <strong>not</strong> have all of the answers.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=166</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>A layoff is not the time to become a freelancer</title>
		<link>http://www.youell.com/matt/writing/?p=140</link>
		<comments>http://www.youell.com/matt/writing/?p=140#comments</comments>
		<pubDate>Sat, 24 Jan 2009 00:50:24 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[essays]]></category>
		<category><![CDATA[rants]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=140</guid>
		<description><![CDATA[I&#8217;m starting to see a trend amid the many layoffs happening right now: Those who have been laid off are being encouraged to freelance. Speaking as a freelancer myself, I can&#8217;t think of worse advice. Everyone&#8217;s situation is different, but the vast majority of people simply are not prepared. It&#8217;s not that most people aren&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m starting to see a trend amid the many layoffs happening right now: Those who have been laid off are being encouraged to freelance. Speaking as a freelancer myself, I can&#8217;t think of worse advice. Everyone&#8217;s situation is different, but the vast majority of people simply are not prepared. It&#8217;s not that most people aren&#8217;t capable: I think most people can handle it in the long run. But the &#8220;long run&#8221; is just that: long! Learning how to work for yourself takes time. I&#8217;ve been at this for many years now and I&#8217;m still learning.</p>
<p>If you got laid off, especially if you have responsibilities, kids to feed, bills to pay, etc. then what you need most is a job. Period. You need cash coming in the door. Taking three or six months to start a business, and burning what&#8217;s left of your savings or 401k in the process, is <strong>not</strong> what you want to be doing right now. Better to spend that time, energy, and money on job hunting and interviewing like crazy.</p>
<p>You may think my discouragement is driven by the fact that I&#8217;m a freelancer. Who needs more competition, right? But that&#8217;s largely irrelevant. There is a big world of work out there. I have very little concern about competition. My biggest challenges day-to-day are ones of my own character. Competition is very far down the list. </p>
<p>I fear that if too many of those who have been laid off listen to the articles, authors, and talking heads out there, in six months or a year we&#8217;ll have a situation that is even worse, as we have a rash of would-be small businesses collapse. And that&#8217;s not good for anyone.</p>
<p>Certainly there are those among you who have what it takes. And you won&#8217;t know if you don&#8217;t try. I can certainly understand that. I would simply suggest that you&#8217;re not directing your own destiny much if you&#8217;re letting a layoff tell you when you can and can&#8217;t start working for yourself. Better to have a strong plan that you can execute in 6 months than to learn to juggle in the batting cages now.</p>
<p>If you absolutely must do the freelance thing, here&#8217;s a small list of advice, for what it&#8217;s worth:</p>
<p><strong>Cut your costs mercilessly.</strong><br />
Cable? Gone. Car? Sell it, ride the bus. Starbucks? $4 coffee? Are you f**king kidding me? You get the idea.</p>
<p><strong>Get Clients (duh)</strong><br />
If you&#8217;re at risk of layoffs, get one or more clients before you quit or lose your job. This is absolutely non-negotiable. If you don&#8217;t do it, you&#8217;re not serious. And if you&#8217;ve already been laid off, set a time limit, perhaps a month. No more than that. And if it doesn&#8217;t work, get back on the job hunt. Don&#8217;t dick around. Trust me. I have dicked around. It isn&#8217;t pretty.</p>
<p><strong>Work part time.</strong><br />
There have been layoffs, but there is still work to be done out there. It might not be glamorous but if money is coming in, who cares?</p>
<p><strong>Work as a temp or contractor.</strong><br />
I&#8217;ve done this myself with great success, alternating periods of freelance work with periods of work as a contractor. (During layoffs contractors are usually the first to go. Later &#8211; when things even out &#8211; contractors are some of the first hires as fiscally-cautious companies need labor.)</p>
<p><strong>Have a specific niche.</strong><br />
Telling people you make websites for independent car dealerships is a lot more meaningful than telling people that you make web pages or that you&#8217;re a programmer, designer, etc. Prospective clients tend to trust niche players over generalists. </p>
<p><strong>Be awesome.</strong><br />
Seriously. You may have slumped a little bit while you were sitting in your gray cube in the middle of gray cubetopia. Now everything you do reflects directly on you. That directly impacts future work and referrals. So you&#8217;d better be good at what you do.</p>
<p>That&#8217;s all I&#8217;ve got. If I knew more I would probably be too busy to write a post like this!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=140</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>The Powell Doctrine</title>
		<link>http://www.youell.com/matt/writing/?p=34</link>
		<comments>http://www.youell.com/matt/writing/?p=34#comments</comments>
		<pubDate>Wed, 03 Dec 2008 05:54:25 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[culture]]></category>
		<category><![CDATA[essays]]></category>
		<category><![CDATA[problem solving]]></category>
		<category><![CDATA[success]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=34</guid>
		<description><![CDATA[I am not a paragon of punctuality but I have improved dramatically from where I started out. I used to be habitually late for just about everything &#8211; even very important things like job interviews.
Several years ago I finally got tired of this. I wanted to figure out how to be someone who could be [...]]]></description>
			<content:encoded><![CDATA[<p>I am not a paragon of punctuality but I have improved dramatically from where I started out. I used to be habitually late for just about everything &#8211; even very important things like job interviews.</p>
<p>Several years ago I finally got tired of this. I wanted to figure out how to be someone who could be on time. The answer I found isn&#8217;t glamorous or fun, and it may seem obvious to some people. It wasn&#8217;t obvious to me though, which is why I&#8217;m bothering to write about it.</p>
<p>Have you heard of the <a href="http://en.wikipedia.org/wiki/Powell_Doctrine">Powell Doctrine</a>? If you look it up you&#8217;ll find a bunch of boring statesman-speak with bullet points, but the best and most concise summary of the Powell Doctrine that I have heard is this:</p>
<p>You go to war with overwhelming force.</p>
<p>This turns out to be the approach I took. I decided that I would be ridiculously early for appointments. If the doctor expected me at 10 o&#8217;clock I would be in his lobby at 8:30 or 9. I&#8217;d bring a book and wait it out. My overwhelming force was time.</p>
<p>This has worked remarkably well for job interviews. I don&#8217;t necessarily show up for the actual interview an hour early (which might seem desperate or at least odd), but I am not averse to sitting in the company&#8217;s parking lot for 45 minutes beforehand. If the meeting or interview is important enough the time is totally worth it.</p>
<p>A lot of common advice about punctuality talks about being 15 minutes early for your appointments. That shit just <em>doesn&#8217;t work</em>. Most people are smart enough to do the math and say &#8220;oh, I have 15 extra minutes so I can stop at Starbucks&#8221;. Then they stress out when it takes 12 minutes to get their coffee instead of the 5 minutes that they&#8217;d convinced themselves it would take. Since they were already running 10 minutes behind, big surprise, they&#8217;re late.</p>
<p>To make this work you need to stick with the term &#8220;overwhelming force&#8221;. If an hour isn&#8217;t early enough, try three. Seriously. If the appointment is that important, why not? Bring a book or your iPod or your laptop. Or convince a friend to come along and keep you company. Do whatever it takes to create that overwhelming force. Absolutely <em>nothing</em> short of death, serious injury, or a kidnapping will prevent you from being on time for an appointment if you leave for the appointment hours before any sane person would.</p>
<p>This isn&#8217;t just idle talk. I did this recently when meeting a prospective client. I was meeting someone in a new part of town that I wasn&#8217;t too familiar with and I was taking public transit. I planned my trip so that I would be in the area an hour early. All sorts of things went wrong that morning: I got out of the house late, I missed my bus and had to walk a mile down to the light rail station. Then I missed the first train and had to wait for another. Finally I was on the right train, heading in the right direction but incredibly late! The train was taking far longer than I expected. I finally got off the train and walked the rest of the way to the meeting, where I was about two minutes early. I felt like a total failure, but I was <em><strong>on time</strong></em>. If I had planned on being 15 minutes early I would have blown the meeting and probably missed out on a new client.</p>
<p>I should say that I don&#8217;t do this all the time. Just like a nation shouldn&#8217;t always be at war. But when force is required, you want to go all the way. I&#8217;m not always on time for every appointment in my life. But I know how to be on time when it counts.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=34</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Names Matter (How I Code)</title>
		<link>http://www.youell.com/matt/writing/?p=19</link>
		<comments>http://www.youell.com/matt/writing/?p=19#comments</comments>
		<pubDate>Tue, 05 Aug 2008 00:24:06 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[How I Code]]></category>
		<category><![CDATA[essays]]></category>
		<category><![CDATA[humane]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=19</guid>
		<description><![CDATA[I&#8217;ve had this website for about 11 years. I&#8217;ve been aware of blogging, in one form or another for about 8 years. But it wasn&#8217;t until this year that I started blogging. I resisted for many years. There were just so many ass-clowns with blogs. Why be another? Still, when I sit and code there [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve had this website for about 11 years. I&#8217;ve been aware of blogging, in one form or another for about 8 years. But it wasn&#8217;t until this year that I started blogging. I resisted for many years. There were just so many ass-clowns with blogs. Why be another? Still, when I sit and code there are often ideas which will come to me and I want to get them out. And yet the topics I&#8217;ve talked about on this site (so far) are technical in topic but not in detail. There&#8217;s a reason for this. It&#8217;s hard to document the mental process you go through when you&#8217;re programming. I tried once this past spring when I was working on a small project with LINQ. But even though I typed out a lot of material, it was very hard to pull together something readable out of it and I eventually gave up. This time I&#8217;m trying a simpler topic and we&#8217;ll see how it goes. The writing is still rough because I wrote it on the spot and backtracked over code I had just written. Hopefully I&#8217;ll figure out how to do this more smoothly in the future because there are ideas and notions, both small and large, which I&#8217;m uncovering every day and would like to share and discuss.</p>
<p align="center">***</p>
<p>I work with several different technologies on a regular basis. Lately I&#8217;ve been working on a .NET Windows app. It&#8217;s one I created originally in 2004 and have been maintaining for a client ever since. I&#8217;ve been adding some new database searching functionality to the app.</p>
<p>To display the search data in the app I have a series of tabs, all of which contain a customized listview. Each listview has a Display() method which takes in a list of things to display. The difference between each list view is the subset of the data shown and how each column is treated. (There are some columns with special handling.)</p>
<p>After a while I notice this pattern where I&#8217;m going to update only the currently visible list view, so I end up with a dispatch table which abstracts away exactly which Display() method I&#8217;m going to call.<br />
I started off with a List for doing dispatch, with each tab&#8217;s index pointing into the table. But that bothered me.</p>
<p>Mainly, I wondered, what would happen if I added or removed tabs in the future? I didn&#8217;t savor the idea of mixed up tabs or a null pointer exception.</p>
<p>At first I thought a hashtable would have the same problem, but that&#8217;s because I was &#8220;complifying&#8221; it, and thinking about using a string for the lookup &#8211; either the tab name or tab text.</p>
<p>Then, &#8220;Duh&#8221;, I thought, &#8220;just use the tab itself as the key&#8221;.</p>
<p>And it really is a duh, because I&#8217;m pretty sure I&#8217;ve gone through this exact same internal dialog many times in the past. Oy.<br />
So eventually I ended up with this:</p>
<pre class="syntax-highlight:csharp">
protected delegate void ListProcessor(List&lt;Item&gt; list);
protected Dictionary&lt;TabPage, ListProcessor&gt; listViews = new Dictionary&lt;TabPage, ListProcessor&gt;();
</pre>
<p>I&#8217;m still not so happy with the delegate since it is almost the signature for map(), and that seems like a smell. Also bugging me is some vague nag about polymorphism which won&#8217;t quite bubble all the way to the top of my brain.<br />
So, anyway, I go on to set up my event handler which captures a tab change. Except there seems to be some kind of retardation here. If you handle TabIndexChanged, that doesn&#8217;t fire if you change the selected tab. You have to handle SelectedIndexChanged instead. Which, in retrospect, makes total sense. But the naming could be a lot better here. I&#8217;m still not entirely sure what TabIndexChanged does, although I suspect it has to do with tab-reordering. Still, <strong>names matter</strong>, and that one naming choice is confusing. Speaking of how names matter, here&#8217;s the handler I created for SelectedIndexChanged:</p>
<pre class="syntax-highlight:csharp">
private void listView1_SelectedIndexChanged(object sender, EventArgs e)
{
    UpdateCurrentListView();
}
</pre>
<p>I wish VS would let you enter the function name as soon as you break it out. I&#8217;m going to have to rename it anyway, might as well.<br />
Since I&#8217;m calling UpdateCurrentListView() from another place, without the event signature, I can&#8217;t just point to UpdateCurrentListView(),<br />
but I can give it the same name.</p>
<pre class="syntax-highlight:csharp">
private void UpdateCurrentListView(object sender, EventArgs e)
{
    UpdateCurrentListView();
}
</pre>
<p>Better? Worse? I don&#8217;t know. Ok, yes, I do know. Better. Just not WOW better. Anyway, onto the meat and potatoes of what I&#8217;m doing. Here&#8217;s UpdateCurrentListView():</p>
<pre class="syntax-highlight:csharp">
private void UpdateCurrentListView()
{
    listViews[tabControl1.SelectedTab](foundItems);
}
</pre>
<p>It&#8217;s just one line of code, but even though I *just wrote it*, I knew I wasn&#8217;t going to know what it did in about 5 mins. I try really hard<br />
not to let things like that go by. People have to read this stuff, and more often than not those people are me!</p>
<p>The name &#8220;listViews&#8221; made sense for the dispatch table when I was first setting it up and inserting functions into it. Actually *using* it didn&#8217;t make sense at all: &#8220;listViews&#8221; sounds like a *list* of *views*. In reality this is a list of functions.</p>
<p>I also am not a big fan of the automatically generated names VS gives things. It works well enough, but it doesn&#8217;t scale at all. You can only have so many textBox15&#8217;s before you gouge our your eyes and swear you&#8217;ll stop programming forever.</p>
<p>Then there&#8217;s the list of items that will be displayed. That list is shared among all of the views in the containing class. When I originally created it, &#8220;foundItems&#8221; seemed like a friendly name. But down here (at this level in the code) you&#8217;re not thinking in terms of things being found. You want to have a more generic idea of what you&#8217;re dealing with.</p>
<p>Some refactoring gave me:</p>
<pre class="syntax-highlight:csharp">
private void UpdateCurrentListView()
{
    displayOnTab[tabs.SelectedTab](SearchResults);
}
</pre>
<p>I realized that while my dispatch table was technically a list or collection, the way I&#8217;m using it is as a multi-dimensional function. So why not just name it like a function?</p>
<p>So that&#8217;s what I did. Also, I&#8217;m only using one TabControl. Might as well go with a friendly name like &#8220;tabs&#8221;. And SearchResults is generic enough so that I don&#8217;t stop and think about the data but specific enough so I have a mental picture of what is happening in the UI when this code executes.</p>
<p>This reads fairly well, is only moderately redundant, and it has a decent English flavor: there&#8217;s a subject acting with a verb upon an object.</p>
<p>Good times.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=19</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>It&#8217;s OK to make things pretty</title>
		<link>http://www.youell.com/matt/writing/?p=17</link>
		<comments>http://www.youell.com/matt/writing/?p=17#comments</comments>
		<pubDate>Tue, 29 Jul 2008 23:43:22 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[essays]]></category>
		<category><![CDATA[humane]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=17</guid>
		<description><![CDATA[I have an announcement to make.
It&#8217;s OK to like pretty things. And you know what else? It&#8217;s OK to make pretty things too.
That&#8217;s right. And not just pretty things others make for you. Not just the candy coated interface you see on your latest OS or on your phone. It&#8217;s OK to make your programs [...]]]></description>
			<content:encoded><![CDATA[<p>I have an announcement to make.</p>
<p>It&#8217;s OK to like pretty things. And you know what else? It&#8217;s OK to make pretty things too.</p>
<p>That&#8217;s right. And not just pretty things others make for you. Not just the candy coated interface you see on your latest OS or on your phone. It&#8217;s OK to make your programs pretty too. It&#8217;s OK to make your docs pretty. It&#8217;s OK to make your website pretty. Pretty pretty pretty.</p>
<p>Aesthetics are important. How you feel about the tools you work with matters. It matters a lot.But making things pretty isn&#8217;t just about aesthetics.</p>
<p>Bear with me here.</p>
<p>Beauty is a form of wealth. And wealth comes in many more forms than we imagine. I&#8217;m not talking tangible wealth &#8211; cars, yachts, bling. I&#8217;m talking about something a little more intangible but still very valuable.</p>
<p>I create wealth all the time when I&#8217;m programming. Again, I&#8217;m not talking about money or the literal value of the code I&#8217;ve written. I&#8217;m talking about the good stuff that just *falls out* while I&#8217;m working. And this isn&#8217;t because I&#8217;m particularly awesome, it just happens. I  think it happens to anyone who works in a creative field.</p>
<p>For instance, say I am writing some code, and I realize that I&#8217;m essentially repeating the same 4 lines of code in several different functions. So I Extract Method and boom, I&#8217;ve created some new wealth which wasn&#8217;t there before. Of course that is more intentional. What I&#8217;m getting at is directly related, but a little different. I&#8217;m talking about a sort of accidental wealth. For instance, say I&#8217;m doing a lot of work with lists. And I realize after a while that I have several places in my program where I am iterating over lists in the same way. So I pull out that code and consolidate it into one spot. Pretty soon I realize that the iteration function I created is handy in a LOT more places. And not just in this one project, but in all of my projects. Pretty soon I&#8217;m coding in a whole new way and I actually start to *think* in a whole new and more powerful way.</p>
<p>I don&#8217;t know what you&#8217;d call this. There&#8217;s probably some huge German word for it which would roughly translate as &#8220;the thing that gets you more things without you seeing it at first&#8221;.</p>
<p>Beauty can work in this same way. For one thing, there is just the simple aesthetic pleasure of working on something pretty. I remember back in the dotcom days I was working on a site that had a pretty UI designed by some skilled graphic designers. I had to start building out the site with placeholder HTML before we had the UI and it was an OK project. Nothing thrilling, kind of ho-hum. But then the designer&#8217;s UI came in and WOW, I suddenly liked working on that project a whole lot more. Of course one of my coworkers was working on an even prettier website, and after a while I really wanted to work on *that* instead, even though I knew that the technology under the hood was awful to work with. Apparently sometimes the grass is always greener, even if the green comes from a spray can. So working on something pretty can definitely improve your attitude about your work, and I would argue that a better attitude improves the quality of your work too.</p>
<p>But that&#8217;s not where all the wealth comes from. It&#8217;s not just the good feeling you get working on it. It&#8217;s the way things play out in your mind. Imagine you&#8217;re building an application and you have some objects that get manipulated. I don&#8217;t know about you, but for me, when I create new objects, especially ones that live in the database, it takes me a while to <em>believe</em> in the thing I&#8217;ve created. Not just believe in whether it will work or not, but to actually think of the thing I&#8217;ve created as <em>real</em>. But when you allow yourself to make things beautiful, to make that a priority on par with functionality and correctness, the things you create become tangible. Icons are a great example of this. Icons &#8211; <em>good icons</em> &#8211; can look great and really add something to your application. I&#8217;m not just talking about the icon for your program, I&#8217;m talking about the icons you pick to represent things within your program.</p>
<p>Think about a personnel database. The typical app that comes to mind is some byzantine Windows app or maybe a clunky web app which dumps out people&#8217;s stats in row after row of icky blandness. Now imagine that instead of row after row of text, there is a thumbnail image of the <em>actual person</em>. And imagine that you can click on that person to get more information about them. Imagine that you can drag that person around by their image. That you can transfer Tricia from Accounting to Distribution Support by literally dragging her from one department to another. Certainly you can do those same things with just text in a list, but it doesn&#8217;t feel the same way. You wouldn&#8217;t see Tricia as a real person. You wouldn&#8217;t *believe* in the idea of Tricia.</p>
<p>And it&#8217;s the same way with any entity in your application. Why should only the user-visible objects in your app have icons? Why should only the user-visible screens look nice? It&#8217;s very common to have programmers build out apps that look great to the customer, but when the programmer needs to get under the hood everything is fugly and lacks imagination.</p>
<p>That&#8217;s not right. That doesn&#8217;t serve anyone. And there are unseen opportunities missed! I&#8217;m not saying to spend all of your time making things pretty. I still stick by my Big 3: Make it Work, Make it Right, Make it Pretty. But making things pretty is definitely allowed and maybe even downright necessary.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=17</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Where the fuck is my Ari Gold?</title>
		<link>http://www.youell.com/matt/writing/?p=8</link>
		<comments>http://www.youell.com/matt/writing/?p=8#comments</comments>
		<pubDate>Mon, 12 May 2008 21:34:13 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[contracting]]></category>
		<category><![CDATA[essays]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software industry]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=8</guid>
		<description><![CDATA[Software development is its own unique thing. It is not a profession that can be directly equated to any other. This tends to frustrate people who try to understand the profession. This is true even for software developers, who would like an established model to follow. This is why you see some software companies run [...]]]></description>
			<content:encoded><![CDATA[<p>Software development is its own unique thing. It is not a profession that can be directly equated to any other. This tends to frustrate people who try to understand the profession. This is true even for software developers, who would like an established model to follow. This is why you see some software companies run like a law firm while others are run like a band of pirates.</p>
<p>Architecture is often seen as a  parallel to software development, leading to the trend over the last decade for everyone who can design a program to declare themselves a &#8220;software architect&#8221;. Of course software is also like plumbing and gardening and a bunch of other professions. And yet it is still unique.</p>
<p>Software by its very nature is an abstract concept, and there are only a few professions that deal in abstract concepts. Law is certainly one. Acting is another, and that&#8217;s what I&#8217;d like to talk about today.</p>
<p>Think about one of your favorite TV or movie actors. Why do you know this person? 99% of the time, you know an actor because of some role they played which you saw and liked. It was probably some great role you saw them in too. You know George Clooney from &#8220;ER&#8221; or films like &#8220;Ocean&#8217;s Eleven&#8221; or &#8220;O Brother Where Art Thou?&#8221;. You probably don&#8217;t know him from &#8220;The Facts of Life&#8221; or &#8220;Streethawk&#8221;. (Remember Streethawk? It was awesome.) In any case, you know most actors by what roles you&#8217;ve seen them play, and how well (or in some cases how terribly poorly) you think they&#8217;ve done.</p>
<p>The software world doesn&#8217;t work like that. Think of just about any well known person in the software world. How do you know about them? Did you see their amazing code? Probably not. More likely you bought their book, or you saw them speak, or you read their blog.</p>
<p>Of course there some exceptions &#8211; programmers who are known mostly for their work. These are almost exclusively in the free software field though, like Linux Torvalds or RMS. (Of course RMS is more like a Tim Robbins: Respected and talented with a passion for activism. But I wince when he opens his mouth.) And even in these cases, most people have never seen any of their code, even though they&#8217;ve probably used it.</p>
<p>If you&#8217;re a great actor, pretty much all you have is your portfolio of work. But that&#8217;s ok: If you&#8217;re talented and had good opportunities, you can point back to your portfolio and get more work. In software it doesn&#8217;t work that way. Sure, you may have a portfolio of work, but nobody cares. Unless you have an existing relationship with an employer, getting hired consists largely of two things: What specific technologies you&#8217;ve worked with lately, and how long you&#8217;ve worked with them.</p>
<p>No one calls up George Clooney and asks if he has recent experience playing a 5&#8242; 10&#8243; lesbian biker with a mohawk. (Although I am now tempted to make that call.)</p>
<p>That sort of thing happens everyday in the software world. Why? Our representation is different.</p>
<p><img src="/matt/writing/lib/images/ari-506x316.jpg" alt="You've got Gold!" align="middle" border="0" height="316" width="506" /></p>
<p>In Hollywood, if you&#8217;re lucky enough to break in to the movie business, chances are good that you&#8217;ve got an agent. You commit to an agent for an agreed upon amount of time. Your agent works actively to find you a part in a movie. You audition, and if you get the part your agent gets a percentage of what the studio pays for you. From what I hear, that percentage is usually in the 10-15% range. Sometimes a little higher depending on what they are doing for you. It is a simple system that seems to work.</p>
<p>The software business in different.</p>
<p>If you&#8217;re a contract programmer like I am, things usually work one of two ways: Either you work for a consulting company directly and you let them find you work, or you advertise yourself on places like Dice and negotiate each contract through a recruiter to get a job you want.</p>
<p>That first scenario is most like having a Hollywood agent. You typically don&#8217;t commit to the consulting company for any fixed length of time, but otherwise it is the same. The consulting company works to match you to a suitable position. You interview for the position, and if you land the gig your consulting company takes a percentage. Except the percentage they take is more like 40%.</p>
<p>If you work under the second scenario, you generally have more control over things, but you&#8217;re also taking more risk of being out of work. More often than not you&#8217;re going through the very same consulting companies to get contracts, but you&#8217;re not staying exclusively with them so you&#8217;ve improved your bargaining position somewhat. You&#8217;ll probably be able to negotiate a better deal than 40%.</p>
<p>There is actually a third scenario where you find your own contract. Often you still need representation either because the client requires it or because you don&#8217;t want to do billing and cash management yourself. In that situation you have all the bargaining power, but even so, the lowest commission I&#8217;ve been able to negotiate is 14%.</p>
<p><img src="/matt/writing/lib/images/ari-and-lloyd-472x316.jpg" align="middle" border="0" height="316" width="472" /></p>
<p>So why can&#8217;t contract programmers have a Hollywood-style agent? After all, most actors aren&#8217;t George Clooney or Tom Cruise. We&#8217;re not talking about the top 1% here, we&#8217;re talking about the average Joe, the character actor. Why can&#8217;t I commit to an agent for a few years, have them find me work, negotiate for me, and only take 10-15% of my earnings?</p>
<p>The answer, as best as I can tell, is commoditization. In our industry the middlemen &#8211; hiring managers, HR people, recruiters, etc. &#8211; work extremely hard to commoditize labor. To most recruiters, if you&#8217;ve got 5 years of experience with C++, you are the same as anyone else who has five years of experience with C++. Never mind that you are an actual person with unique skills and personal qualities that are hard to encapsulate in a resume.</p>
<p>This can be greatly frustrating at times. Most recruiters out there are non-technical people. They aren&#8217;t idiots, but most aren&#8217;t passionate about what they do and are generally focused on short term goals. Their job becomes one of matching up acronyms in the job requirements with acronyms on your resume. This is reinforced by hiring managers within their client companies, who are almost always in some huge hurry. This system practically guarantees that the best people for a position will never get selected.</p>
<p>Even more frustrating is the need to go through the negotiating process every time you want to work. Really, that&#8217;s what an agent is for, and sorry, you&#8217;re out of luck there. There are no true agents in this business. Instead, you get a recruiter who either deals in large volume or fat margins. The amount of money they make pimping you is unlikely to be much different than the money they would make pimping someone else. Multiply that by hundreds of developers a year and it all averages out. Why bother to cultivate a personal relationship with talent?</p>
<p>If you&#8217;re a movie actor, when you complete a film you have something tangible to point back to and say &#8220;I did that&#8221;. Not only that, but thousands or maybe millions of people have seen what you did. Your unique skills and personal qualities come through.</p>
<p>If you&#8217;re a programmer, when you complete a project, even a highly visible one, you can also say &#8220;I did that&#8221;. The difference is only a handful of people are really going to understand what you did. Any programmer who has tried to explain what they do to their mom knows what I&#8217;m talking about. Is it any wonder that programmers have to turn to non-programming means to stand out?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=8</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creole (or why I&#8217;m not down with the JVM)</title>
		<link>http://www.youell.com/matt/writing/?p=7</link>
		<comments>http://www.youell.com/matt/writing/?p=7#comments</comments>
		<pubDate>Wed, 30 Apr 2008 23:20:16 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[culture]]></category>
		<category><![CDATA[essays]]></category>
		<category><![CDATA[needs revision]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[programming languages]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=7</guid>
		<description><![CDATA[A lot of languages are seeing ports over to the JVM these days. I don&#8217;t think that&#8217;s a very good idea.
Why? I&#8217;ll spare you a long exposition. The answer is this: Java&#8217;s libraries suck. Yes, there are tons of libraries for Java. And yes, I&#8217;m sure very smart people wrote them. But that&#8217;s actually part [...]]]></description>
			<content:encoded><![CDATA[<p>A lot of languages are seeing ports over to the JVM these days. I don&#8217;t think that&#8217;s a very good idea.</p>
<p>Why? I&#8217;ll spare you a long exposition. The answer is this: Java&#8217;s libraries suck. Yes, there are tons of libraries for Java. And yes, I&#8217;m sure very smart people wrote them. But that&#8217;s actually part of the problem. An awful lot of a language&#8217;s character comes from its libraries. Better said, libraries encapsulate culture. So when your culture devalues simplicity, your libraries will reflect that. Worse, they will <em>propagate </em>that.</p>
<p>I&#8217;m sure the JVM performance is wonderful, and it has no doubt been analyzed to death to make it shiny and lickity-splickity fast. But it seems like an awful lot of people want to get their oddball language on the JVM to take advantage of Java&#8217;s libraries.</p>
<p>That&#8217;s just crazy talk.</p>
<p>For the first few years of my career I was a C++ programmer. Pretty serious about it too. I loved me some C++.</p>
<p>At that time there weren&#8217;t a ton of libraries for C++. Not by today&#8217;s standards, anyway. In fact, a lot of the libraries I used were directly descended from C or were just straight C libs that had been around forever. So for me, at that point, C++ really was a C with an object system and a few extra bells and whistles.</p>
<p>When I started to learn Perl, my expectations of C++ changed. Which eventually led me to the STL. The STL was a huge leap forward for me. It was only at that point that I felt like I was seeing C++ as its own language. Before that I could only see it as a C.</p>
<p>Many years later, when C# was announced, I winced. Here was M$, and it seemed they were going to just blatantly clone Java and everything that came with it. But that&#8217;s not what happened. Aside from out-iterating Java, the .NET platform (and therefore C#) actually got better libraries. Much better, in some cases. In other words, they managed to capture a lot of the advantages of Java without absorbing too much of the culture.</p>
<p>Similarly, a lot of people who liked VB 6 feel that VB.NET is hobbled because it has to be compatible with C# through those same .NET libraries. And they are probably right. VB culture was hugely impacted by the move to .NET.</p>
<p>So, language designers and porters, look before you leap. Putting your language on the JVM brings it closer to Java, a platform whose values are probably the exact opposite of yours. Don&#8217;t be surprised if your culture changes.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=7</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stockton Syndrome</title>
		<link>http://www.youell.com/matt/writing/?p=6</link>
		<comments>http://www.youell.com/matt/writing/?p=6#comments</comments>
		<pubDate>Thu, 17 Apr 2008 04:41:07 +0000</pubDate>
		<dc:creator>matt</dc:creator>
				<category><![CDATA[conferences]]></category>
		<category><![CDATA[essays]]></category>
		<category><![CDATA[problem solving]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[travel]]></category>

		<guid isPermaLink="false">http://www.youell.com/matt/writing/?p=6</guid>
		<description><![CDATA[I don&#8217;t know about you, but lately I&#8217;ve been seeing lots of ads for conferences here and there. I just missed PyCon &#8216;08 in Chicago. I&#8217;ll probably miss WWDC in SF this summer. And the odds of me making it to another OOPSLA are slim to none these days. Still, I try to be optimistic [...]]]></description>
			<content:encoded><![CDATA[<p>I don&#8217;t know about you, but lately I&#8217;ve been seeing lots of ads for conferences here and there. I just missed PyCon &#8216;08 in Chicago. I&#8217;ll probably miss WWDC in SF this summer. And the odds of me making it to another OOPSLA are slim to none these days. Still, I try to be optimistic about such things. From time to time a conference will catch my eye and I&#8217;ll give some thought to attending. And so I saw a blurb the other day for the eBay Developers Conference in Chicago this June.</p>
<p>Not being big on flying, I headed over to Amtrak to see how many arms and/or legs they wanted for a ticket.</p>
<p>For the most part I have no real problems with Amtrak. They are running an under-appreciated and underfunded service in an almost non-existent market on tracks they don&#8217;t own and have no control over. Many people I&#8217;ve talked with over the years say they long for a European-style rail system where train travel is widely available, simple, and popular. Amtrak will never be any of these things, sadly. There&#8217;s just too much that needs fixing. But I digress.</p>
<p>Amtrak has a decent website with features and functionality that have steadily improved over time. Like any other travel-industry website there is a small learning curve, but for the most part it is easy and pleasant. That pleasantness even extends to the check-in procedure at the station. If you order your ticket online you can pick it up from a simple automated kiosk that will print out a neat little ticket that is a classic example of how forms should be designed. With it&#8217;s classic 50&#8217;s styling you&#8217;ll feel like Cary Grant in North by Northwest. Bring your own Eva Marie Saint.</p>
<p style="text-align: center"><img src="http://www.youell.com/matt/writing/lib/images/SalemAmtrakStation_400x300.jpg" alt="Amtrak Station, Salem OR" height="300" width="400" /></p>
<p>Don&#8217;t be fooled though. The website, the modern kiosk, and the wonderful ticket design all hide a secret that you probably already know: Amtrak is fucking insane. Like &#8216;Kramer doing stand-up at the Apollo&#8217; insane. Like Cameron Diaz in Vanilla Sky insane. I think you get my point.</p>
<p>Still, the train is the train. Biggest thing I like about the train? It will never, at any point, fly at 30,000 feet. Call me crazy, but I&#8217;ve got a thing about sitting in a fuel-filled aluminum tube 6 miles in the sky. I&#8217;m sure it&#8217;s just me. Whatever.</p>
<p>So I went on the Amtrak site, punched in PDX to CHI, selected June something-or-other for the dates, and presto, here&#8217;s what they gave me:</p>
<p><a href="http://www.youell.com/matt/writing/lib/images/FullSchedule_597x771.png" target="_blank"></a></p>
<p style="text-align: center"><a href="http://www.youell.com/matt/writing/lib/images/FullSchedule_597x771.png" target="_blank"><img src="http://www.youell.com/matt/writing/lib/images/FullSchedule_597x771.png" alt="Amtrak Schedule" height="386" width="296" /></a></p>
<p>Do you see what I see?</p>
<p>In case you can&#8217;t read their time table, this lists four possible trips that I could take to get to Chicago. So far, so good. The first trip looks best: Portland to Chicago, straight through. No muss, no fuss; $245.</p>
<p>The next two are a little more complicated. I can take the train to either Seattle or Spokane. Then I get to dick around for a while before catching a connecting train to Chicago. No savings to be had here. In fact one is mysteriously $26 more.</p>
<p>And then comes my favorite, trip #4. It&#8217;s a chance to save $25! For clarity I&#8217;ll describe the itinerary:</p>
<ul>
<li>I take the train from Portland to Sacramento.</li>
<li>I take a bus from Sacramento to Stockton.</li>
<li>I take another train from Stockton to Bakersfield.</li>
<li>I take the bus from Bakersfield to LA.</li>
<li>I take a final train from LA to Chicago. (Assuming I made my connection in LA. Trust me, I wouldn&#8217;t.)</li>
</ul>
<p>So to sum up, I take trains and buses 1000 miles <em>south</em>, then I take a train 2000 miles <em>northeast</em>. Eventually this gets me 2100 miles <em>east</em> of where I started. Just like Pythagoras said, right?</p>
<p>Here&#8217;s the stats:</p>
<ul>
<li>Total distance: roughly 3000 miles</li>
<li>Total time: approximately 66 hours</li>
<li>Total savings: $25 (No, not priceless. Sorry.)</li>
</ul>
<p>Why the hell would Amtrak even suggest something this inane?</p>
<p>Clearly they are taking the <a href="http://en.wikipedia.org/wiki/Traveling_salesman_problem">Traveling Salesman problem</a> way too far. Actually, I take that back. I have no idea what they are doing algorithmically over there. The real problem &#8211; from a user standpoint anyway &#8211; is that they aren&#8217;t filtering well.</p>
<p>There are very few parameters to this problem: My needs are simple and specific; their abilities are limited and finite. As far as I&#8217;m concerned, there should be no more than three possible trips presented when the parameters are so few. Why three? Because there are only three factors at stake that either customers or Amtrak care about. What are they?</p>
<ol>
<li>Price</li>
<li>Time</li>
<li>Quality</li>
</ol>
<p>Notice I say &#8220;no more than&#8221; three trips. In this particular case there should only have been two shown to me. Let&#8217;s work through it:</p>
<p>Right away we see that Trip #1 is priced lower than Trip #2. Notice that Trip #2 takes almost 4 hours longer. And it has a connection. Connections equal risk, and risk equals lower quality. So Trip #2 is out.</p>
<p>Trips #1 and #3 are the same price, but Trip #3 shaves about an hour off the travel time. The quality is lower because there&#8217;s a connection, but it is only one connection and it is train-to-train. I&#8217;d keep this in the list. You never know who wants to save that hour.</p>
<p>Finally, Trip #4 is cheaper than any of the other trips, but it is over 20 hours longer!! If that isn&#8217;t enough of a reason to shit-can it, there are four connections, alternating between trains and buses. Throw in a plane and some pillows and you&#8217;d have a John Candy movie.</p>
<p>Wait.</p>
<p>Those aren&#8217;t pillows!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.youell.com/matt/writing/?feed=rss2&amp;p=6</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
