some simple programming advice

I found the following at Kevin Element’s website. This article was written by Robert Hodgin, an interactive artist and media guru, after presenting at the EYEO Conference in 2011. You can find Robert’s site at www.flight404.com, or www.roberthodgin.com

Iterate

Your first attempt at anything is likely going to suck. Let’s face it, most of us are not phenoms. In fact, I cannot think of a single person I have met in my 38+ years who was able to excel at something shortly after trying it for the first time. We all need practice, and lots of it, for everything we try. From learning to talk and walk, to learning to play an instrument, to learning to drive, to learning how to be a social creature… it all takes practice.

Want to know how to get better at something? Do it over and over. And over and over and over.

However, it cannot just be mindless repetition. There are two additional factors that need to come into play. You need to also do the following:

1) Correct. You should work on fixing the things that didn’t go right with the previous iteration. Make a list of the things you want to address. Tackle the big items when you have a clear head and a nice block of time. Otherwise, pick off the smaller ones. However, don’t get overzealous with your corrections. If you happen to mutate your project into something interesting but unintended, save this mutation so you don’t overwrite it. I have lost some nice bug-made oddities because I was too concerned with fixing errors.

2) Improve. You should research the field to try and learn things to add to future iterations. This means looking at what people have already done and also what people are trying to do. Staying on top of advancements in your field of interest is definitely worth the effort. Unfortunately, this may mean you find yourself looking over SIGGRAPH white papers or University theses that are over your head. This is fine. Don’t get too caught up with not understanding what is written. Just look at the pictures if that is all you can manage. The important thing is to continually expose yourself to information about your interests.

Collaborate

I don’t know how many of you played D&D as a kid (or as an adult… no judgement here) but I will speak now as if all of you have. When you roll up a new character, unless you cheat it is highly unlikely you will create a demigod. You might have a 18 here or a 16 there, but you will never ever roll up a character with an 18 for every attribute. Ideally you will have one high attribute, perhaps an 18 strength. With an 18 strength, you would make a fantastic fighter. So off into battle you go.

But life, fantasy or not, is never easy. Your first run-in with a couple filthy thieves results in a gash across your chest and you drop half your hit points and suddenly you start to suffer the reality of the situation. You need healing abilities. So what do you do? Well, you don’t go running to the library to start a multi-year process to learn how to cast a healing spell. Instead, you find a cleric who has an 18 wisdom but happens to suck at fighting and you join forces. Now, you are much more powerful than the sum of your respective skills.

And the beauty of this setup is that nobody feels like they are being taken for granted. The fighter has an intense appreciation for the healing abilities of his new cleric friend, and the cleric is thrilled to have found someone that can fight off the horrible monsters that lurk out in the wilds. So if you are a fighter, find yourself a cleric friend. If you are a cleric, track down some muscle for hire. Because if you don’t, you will live a limited life and never get to see what is on the other side of the dark forests at the base of Mount Craggyspire. Or whatever.

I have spent much of my coding career learning how to manipulate particles and figuring out how to make OpenGL make things pretty. But I suck at many other aspects of coding. Which is why the projects involving collaboration ended up being the most successful. The visualizers I have made with Andrew Bell, and the Planetary iPad app which I am currently developing with Bloom… those projects have meant the most to me and I am damn certain I would not have been able to make them on my own.

Baby Steps

I went through a talk I gave in 2004 and saw a slide that, though a bit harsh, still represents the best advice I can give to young idealistic coders. It said, in bright red on white, TAKE TINY STEPS OR FAIL!!! and the FAIL!!! bit was flashing on and off for emphasis.

A problem I suffer (and hopefully it isn’t just me) is that I see something awesome someone else made and it gets my mind churning and I start thinking “I can totally do a 3D terrain simulation with physics, CLoD implementation, and realtime weather effects” so I dive right into XCode and start making my Globe class and the Weather class and on and on and before you know it, I feel extremely overwhelmed which usually has me running for the remote so I can watch science documentaries in an attempt to distract my bruised ego. Knowing exactly what you want to make can often be the largest barrier in your creative journey.

My advice in this situation is to take some time to break the problem up into bite size pieces. Work on little prototypes. Explore each tiny concept and eventually, start to put them together. If you are too focused on the gap between what you envision and what you currently have, you will likely lose faith.

Plus, if you have a bunch of well-understood bite size pieces, it will make it much easier to combine them into bigger projects. But if you start in with building a big project, it is much more difficult to pull out the pieces you want to repurpose later.

Take a walk or a shower

This may not work for everyone but it has been very useful to me. If I am stuck, either creatively or programmatically, I go for a walk. Or if it is late in the evening, I will take a hot shower. Something about those two activities really helps me clear away the mental fog and helps me to focus on the issues at hand. I have cleared many a hurdle just by putting on my headphones, slipping on some shoes, and going for a walk through the neighborhoods of San Francisco. This doesn’t mean walking over to the neighborhood bar for a drink. Walk while mulling over the problem at hand and head home when you have an idea of what to try next.

I realize what I am writing here is nothing new. We have all heard these points made by many. They have reached rockstar cliché status. But this doesn’t mean it isn’t worthwhile to be reminded every now and again.

Ira Glass on creativity: http://www.youtube.com/watch?v=BI23U7U2aUY