Saturday, January 2, 2010

The Little Details

As Jeff Atwood said:
Ah, yes, the stereotypical programmer response to most projects: it's trivial! I could write that in a week!*

I thought it was just me, apparently it's not. It turns out that all programmers think that way, they see Twitter and they think "A table for users, a table for tweets, a user page, and a settings page."

Let's face it, we all think that way, and the surprising part is? It's true; you CAN create a usable version of Twitter over the weekend, you CAN create a usable browser in a weekend, and you CAN create a usable version of Stackoverflow in a weekend.

Why does software take us so long to create then? There are two reasons: The little details and the little details.


  • The little details: The first little details refers to the little details of writing code, for example, the little silly bugs that take ages to find, spelling mistakes, forgotten variable definitions, wrong passwords, wrongly placed files, difficulties with the programming language/framework being used, etc.. All these are problems that a programmer faces that take much of his time but there's no way to predict them.
  • The little details: The other little details refers to the little details of a website/software that a programmer usually doesn't think about when making the one-weekend claim.
The best example of this is the reason why I wrote this blog post: In the project I'm working on now, it took me barely 30 minutes to create both the interface and the tables (what programmers usually start with in a project). What comes after that is what usually takes long. Because of some previous experience with Flex, I decided to implement the login system next, so I googled for a way to do it with Flex and Zend and the way that I found required the use of Cairngorm, having used it before, I didn't mind using it now. So I started changing my project to use Cairngorm, separating the different screens into views, adding the model, the controller, the VOs, etc... I started creating the PHP files. After about two hours I had a working login system. Next I wanted to populate a tree control with some data from the database, now because I didn't know how to do that in Flex it took me about 6 hours just to do that, as simple a task as it is.

Programmers don't like planning ahead and dealing with charts and stuff, we like writing code, and I don't see any way to change that any time soon; programmers will still want to write code before they plan, it's in our blood.

No comments: