Challenge: Code With Your Eyes Closed

I have noticed something very different about how I develop my own projects compared to the ones where I’m working for someone else.  It’s a pattern I think many people follow in how they tackle hard intellectual problems in a work setting based on the expectations of others.

When working on my own projects I often find myself sitting in a comfortable chair to think.  I close my eyes and ponder various solutions, wrap my head around implementation details and workout the complexities and issues that might arise when I implement it.  All that thought usually results in some a-ha moments and hopefully less re-work.

On the other hand when working with a team or for someone else I’m anxious to show progress every hour of effort. This means more thinking while doing and occasionally finding myself in a spot where I need to stop and refactor, or re-implement something differently.

It occurred to me that refactoring code in your head is very quick. So the iterations are also quick on improving the design of any solution.  It’s very easy to just toss out an entire train of thought and start somewhere else, but tossing out 100’s of lines of code can feel like a loss.  There could be orders of magnitude better productivity if people spent more time quietly contemplating their code before writing it.

The other thing I find is that when I really know what I’m going to write, having thought about it deeply.  The coding part is just a matter of typing my thoughts out into the computer.  It is then that typing speed can actually become a limiting factor in how fast you can code – rather than splitting time between thinking and typing.

It seems that as I’ve gained experience, my effort of thinking about how to implement something has given way to instinct and habits.  Which is a good thing.  But sometimes there are particular problems that demand a thoughtful response and for those maybe the best place to accomplish great work is from your comfortable Lazy-Boy.