Skip navigation

Tag Archives: Programming as Creation

I’m a programmer, though I’m really only an amateur right now.   I’ve written programs in C++, C, and Pascal.   My first language was Pascal, Turbo Pascal specifically.    I love the act of programming, but when I attempt to explain what programming is like, I often find myself at a loss for words.   What does a person do when they code?   My best metaphor has always been that coding is like writing or creating music.   It’s an act of creation…an art.

What does that mean?   Art is often thought of as creation ex nihlo–creating out of whole cloth.   But that’s not true.   A writer uses a known language, with a known grammar.   When she writes, she writes with an eye towards her genre.   She might borrow from the generic conventions or go against them.   But few good writers ignore them.   A musician will tend to pick a certain key and a certain scale.   He doesn’t have to, but the alternative, composing in the chromatic scale (using all possible notes), is often less pleasing and more difficult to compose in.  He will also compose with the conventions of his genre in mind.  He could use, ignore, or even self-consciously twist the conventions in an attempt to make the statement he wants to with his music.   In each case the artist is remixing, for a lack of a better word, the conventions and limitations to express his or her own statement.   They are using a library of pre-built words, expressions, biases and beliefs to achieve their goal.   My question is, understanding all of that, how could you view coding as anything else but art?

When you code, you choose your limitations.  Your language decides what you are capable of expressing.   Coding in C++ is always different, and always causes a different result, from coding in Lisp, or even Assembly.    The language, like a scale, limits your options and, by doing so, enables the coder to accomplish certain things more easily.   It is interesting to consider that when you finally start to program, you will usually be programming for an application which has been implemented before.   Yet, your code, and your final product, will inevitably be different from them.   Or, to put it another way, it isn’t just a coincidence that programmers will write the same program or even the same functions in different ways, even if they use the same language.   When I code a program, I’m expressing my own personal beliefs and biases about how that program should work.  It might be better or worse than someone else’s implementation.   That doesn’t matter because unless I am attempting to mimic someone else’s coding style, I will always code how I believe a thing should be coded.   A more “zen like” way to think of the problem is this.  I can only code as I would code, or code as I think others would code.    I can never code as a different person codes because doing so would require me to be that person.

Thus coding is not only a form of art, but a form of personal expression.

I know that seems funny.  But even in the most staid task, the coder cannot escape the fact that HE is always coding and that the code will either reflect his beliefs or what he believes his boss’ beliefs are about the best way to implement the program.   In each case, (excluding the case where the programmer is essentially copying someone else’s code) the programmer is the filter through which the code is passed and the programmer is the “designer” or “creator” of the code.