Fog Creek Software
Discussion Board

Sex, Drugs, and Sheet Music

In thinking about the process of programming, do we dwell too heavily on the science of it, and not enough on the creative side? I've spent more of my life as an artist than programmer, and you see these same kinds of arguments in that world as well - Is playing rock and roll hard? Are orchestras a better approach to music? Are they soulless?

As for rock and roll - like sex - if you are finding it hard probably you are doing it wrong, or at least for the wrong reasons. But even in a orchestra, or any other type of art form, all you are really trying to do is hit that 'zone' where good things happen. People talk about this in programming as individuals, but what is really important is that the project itself hits the zone, not Joe's afternoon. Humans have the ability to pool their minds, all get on the same page, and think as one. Obviously this isn't a very understood science, but I'm sure you've all worked on projects where things were 'cooking', and ones where they weren't.

Sometimes a good spec, sheet music, a good conductor can bring this out. Sometimes though, that can kill the dream too - maybe you get there like a jazz band, or maybe you are all wild and hairy, and someone screams 'Baby we were born to run!' and it syncs you up like magic. I find even drawing goes best on those rare days when you can just let go, quit trying to be clever, and let your hand do what it knows to be right.

Programming is interesting because it must be part logical (there is a processor after all) and part creative (most decisions you make have no correct answer). It is, imo, a mistake to force a process on this too tightly. A process just means that if you don't all get in the zone, you still get some kind of result eventually. At worst, it means no one is allowed into the zone, because we can then predict the outcome better. Why are scripting languages so popular, or VB, or cowboy coding? We like to think that its because 'those' people aren't clever enough to understand the complexities of a rigid system, but is that really it? Do programs made under such systems always succeed? Does it always fail when you program from hip? Nope, and nope. Maybe that kind of person just gets there that way..

When painting or dancing or playing in a band, you want everyone to be really good (in fact way way beyond the 'aha' question level), and they have to be passionate about what they are doing (everyone is passionate about something, so I think just 'is passionate' doesn't cut it - it has to be "is passionate about Seattle grunge, but the damn stuff never has enough bass!"). Also, you have to genuinely respect each other (I think a good measure of this is watching reactions to little banal jokes - people that like each other will laugh/smile at nothing, and they can't fake that). I think you also have to believe what you are doing is important somehow. You also have to eventually get some form of recognition and appreciation, even if just from one person that matters to you.

Well, that is how I see it from the 'art' side, I think it applies to programming as well though. Obviously you can make software purely with a process/formula (and a band for that matter), but to get to the next level you need more than process, you need the zone, the 'G' for groove, you know who you are baby... I think we shouldn't dismiss all the people in the world winging software as being 'incorrect', rather take it as customer feedback, and facilitate it somehow. And not lose sight of the programmer inside us, who likes to fuck around with computers and do dumb things because it feel good.

I bet someone here disagrees though!

Laughing at all of your banal jokes,

Robin Debreuil
Monday, August 12, 2002

Beautiful post, Robin. I've thought about this some, and while I do see some clever bits in coding that are often referred to as "art", speaking for myself, I don't think I work any art in when I am programming. I also think that in spite of the number of programmers that say programming is art, it is not.

As an artist, I had a comic strip in a newspaper for a year, as well as a magazine cover. As a musician, I paid for a good part of my college tuition. As a writer, I had several short stories and  magazine articles published, and even wrote a part of the bcp chapter in "Hitchhiker's Guide to Visual Basic and SQL Server" (I'm credited in the chapter itself, and I beleive Mr. Vaughn provided my batch set/data set/demo script set on the CD). 

However, as a programmer, I can't think of one case where I did something that would qualify as anything other than dottings Is, crossing Ts, and choosing what I beleived to be the most readable and the best compromise of performance, memory use, etc.. It also makes me wonder a bit about our definition of art, and whether even my own art qualified as art, or as programming words, ink, or sounds for a desired result.

I guess I have a problem defining "art." I think for most people it has a couple meanings: the production of things we refer to as "art" like paintings, music, or words, no matter how skillful the creator; or the creation of a clever or interesting piece of work, even one not traditionally referred to as "art" by someone highly skilled in the subject at hand.

I'd argue that the musician that adjusts their playing style is making the same kind of decision the programmer makes -- it's the best way to present something given the circumstances. It could be a certain tone produces better resonance in a given hall, or that more volume and less complexity is required in the outdoor setting, or that a particular flourish sounds best with note spacings altered.

The other difficulty I have in calling programming "art" is the nature of the job. Traditional drawing, painting, and musical instrument-playing are as much learned physical skills as mental. Writing words and programming have essentially no physical component. There are only so many ways to write a loop; there are no strings to bend, no valves to half-press, no sound-box to tilt. You cannot alter the order of the words to evoke a particular emotion.

I think in that word, "emotion," may be the essence of what art is, to me -- the ability to produce emotion through performance. I don't see how code that does that (error message jokes notwithstanding).  There may be design decisions that are better for the user, but the provocation isn't the same as a painting, dance, or what-have-you.

So, what is the creative side of programming? I'm not sure there actually is one. I think the creation happens in the concept and design, and the rest is just a mapping of design to cpu instructions.

Troy King
Monday, August 12, 2002

"I think in that word, "emotion," may be the essence of what art is, to me -- the ability to produce emotion through performance.
So, what is the creative side of programming?"

Producing software that makes users beat their heads against the keyboard in frustration?

Monday, August 12, 2002

Yeah, the ultimate goal of art is usually some sort of emotional response, but maybe more generally any type of mental response - I'm thinking things like escher, or maybe a thought provoking short story would fall outside of 'emotional'. In that sense the software/user conversation fits right in.

Anyway, its more the idea that we do some things logically (more consciously processed), and some artistically (bubbling up from the back) (maybe art isn't exactly the word, ok). I'd say spec'ing software is almost exactly the same process as writing a song, certainly very creative, and you pull on all kinds of knowledge, experience, references, judgment calls etc. Then if writing the software is like playing it, the question is how much room do you allow for interpretation (which means how completely do you define it before you start). The gamut runs like music there too. You have the jazz approach - lots of skilled people familiar with standard patterns, each bringing a bit of themselves to the table. I think lots of games are made like this. Then the orchestra approach, everyone plays to sheet music as the conductor tells them to. 'Serious' stuff is made like this. Or the Rock and Roulez approach, everyone agrees up front on a minimum and just goes for it in the key of G. Most software you see seems to fall in this category ; ).

I don't think nuclear reactors should use the rock and roll approach, just like flying javascript logos don't need a twelve page spec and schedule. But everything in between could probably benefit from taking a 'bit of both' approach. It is well documented and obvious (to most here anyway) how 'cowboy coders' could use a more formal approach, but the question is more, is there any benefit to allowing a bit of winging it in a formal process? (suppressed laughter).

Mostly I think the process you use affects the 'personality' of a program (muffled screams). Part of that is the OS it runs on, part is the spec, but I also think a lot of that is the attitude it was made with. Think media player vs winamp - winamp is a disaster for usability (we used to use winamp to convert mp3's to wav files, but who would know you even could?), yet there is something about it that matches the attitude of your average mp3 pirate obviously. I once read how Populous (a game) was made by first making a 3D globe, then fooling around with it until the game come out. It worked, made money, and had a sequel, and it was very groundbreaking, or so I'm told. I doubt you could get that kind of creativity writing out everything down to private-field-names-and-types before hand. I'm really not a big game fan, but I do think that creativity in software is very important. All improvements by definition have to be outside todays standards. So is there room for experimenting and fooling around in your process? If someone comes to you with a bizarre way to open a file, do they get a lecture or a lollipop? What if that was drag and drop - someone must have done that when it wasn't considered normal?

What I don't believe is that with programming, it is possible to scientifically make the structure rigid and defined enough that you end up with a well oiled software machine that spews out mountains of profitable code with few bugs. I think that would be more like the way we applied the scientific approach too rigidly to government, and ended up with the disasters of the last century. Or the way we apply the scientific approach to opinions, and end up with philosophy majors.

Everyone equates bug free well written code with success and profit, but have their been studies on new ideas and success? I don't know, but there is a lot of somewhat buggy code with a good idea that is successful, and a lot of air tight stuff that isn't. If it is the case, then maybe its worth a few rough edges if it gets you a few new ideas...

I'm mostly wondering about all this because I've made enough money off crappy code that I'll be going to hell if its a sin.


Robin Debreuil
Monday, August 12, 2002

Man, you're talking my language!

Reminds me of my time back in university when I'd tell people their program wasn't working because their code didn't rhyme...

I certainly think there is an artistic element to programming. I mean, when a team of coders are working so closely that they can predict how each other will think, is that really that much different from a bunch of Jazz musicians or even an orchestra. I've worked in small teams where we kept the spics fairly minimal, but we all knew what each other was doing, and it all fitted together, though the beat may have been synchopated. And I've worked in teams where we all followed the sheet music and the conductor's baton, but we still made music. We were still creating, we just had a more exact definition of what we were creating.

An engineer builds a bridge to fulfill a function. It must be strong enough to carry the required load across its span. It must be able to withstand the forces of nature. But some bridges are truely objects of beauty. Others are ugly as sin. The ugly ones perform their function just as well as the pretty ones, but whenever we see them we say "why did they let that ugly bridge be built?"

It can be the same with code. Some algorithms form elegant, nicely indented and easily readable blocks of code which are just a joy to program. Some simply don't. Or perhaps there's an elegant way to code it, but the programmer missed it and the result is an ugly piece of code which is difficult to understand. Or sometimes real-world problems get in the way, and what was once an elegent piece of code ends up an ugly monster because it needs a dozen #ifdefs to get to compile on different platforms.

The question is: what is art? Does art have to have no function other then enjoyment? Is the beautiful bridge art? And if it is, in the same way a painting we hate is still art, doesn't the ugly bridge also have to be art?

I'm sure most would agree that a computer program's function can be artistic. For example, photo retouching, film editing and 3D rendering software all serve in the creation of art. Many would even agree that computer games are art in the same way movies are. But I think what we're asking now is can the program logic itself be a form of art.

I would argue that it can. Maybe one day programmer's professional bodies will have awards for elegant code in the same way architect's bodies give awards for elegant buildings.


James Shields
Monday, August 12, 2002

Personally, I think of what I do as a programmer not as an art, but as a craft.  Related feeling, but not the same thing.

As a musician, I work with my bandmates to write music that moves us, and with luck moves other people as well.  Our only limitations are our creativity and our technical ability to play what we've written.

As a programmer, the first, overriding concern is making something that works.  I can take a craftsman's pride in doing the job elegantly or in coming up with an original solution to a problem, but if it doesn't work according to specifications, I've failed.

A couple of years ago, our local art museum had an exhibit of chairs as art.  There were some wild and crazy interpretations of what a chair was about.  Many of them were extremely creative.  Most of them would have been absolutely awful to sit on.  In contrast, think about how a master craftsman from 100 years ago might have built a chair.  The design might be elegant, there might be some pretty designs on the side, but fundamentally it would be sturdy and comfortable to sit in.  That's how I see my work as a programmer.  I'm a craftsman.  Someday, I hope to be a master craftsman.  My all-out artistic impulses I save for my music.

Tony Dismukes
Monday, August 12, 2002

Hmm..  I've worked both sides of the equation and I don't think programming is art.

Unless you are working at someplace like Pixar, of course, where you create code to support art.

For one, I'd go nuts if I just coded and never did my art.  There's no emotional artistic expression in my code.  It just does things.  It often requires creativity, but not artistry, so I find myself working on my art in my spare time to let out my artistic juices.

See, it's like calling a techno DJ a musician.  Some of them delve pretty far into musicmanship, like when a good DJ mixes 2 or 3 songs at once, but overall, they just play disks and don't really create new music.  They are the engineer who creatively sequences existing songs together to properly work the dance floor.  The artist is the person who wrote the songs that the DJ put together.

Monday, August 12, 2002

Art doesn't exist. It's an evil meme with one goal: Exclusion.

"I'm a artist and you're not. This is art and that's not."

It serves no useful purpose.

I'm a programmer, composer and keyboard player. I am not an artist; nor is anyone else.

Dan Sickles
Monday, August 12, 2002

The whole art/craft thing mostly comes down to how seriously you take yourself I think. Certainly there are duck carvers that I admire as artists, yet they would hesitate to call themselves that. And ~(x) that too...

Whatever it is, is there room for the artistic process in writing (not spec'ing) code? Say you have a class that you are writing, and you think it needs to be split into two. Is it ok to just eyeball it, or are you better with a formula, or is changing the spec to big an issue for something so trivial? If a program feels a bit obtrusive, is it ok to go in and cull a few popups? Should that security dialog get punched up a little? If you find some nifty side effect in your code, can you throw it in (like winamps mp3 converter)?

I really like the ugly bridge analogy, and certainly architecture is one of the most productive metaphors for software development. But I think we also have been sold a bill of goods, taking only their fairy tale version of the process. Usually they have the architect, the foreman, the accountant and the customer all with their own ideas, and their own real limits on what is possible. And amidst all their shifting requirements, retrofits, kluges, and spoiled works of beauty, they secretly dream of object oriented programming. Where you are free to implement your designs exactly as you see them - because bits are free and computers are mathematically perfect (at least that's what I'd tell them).

The thing I like most about well written/structured oo code is it lets you swirl things around a bit as you go. Not because the pointy haired client changed the requirements, more because you have that 'needs a little red' feeling and you can do it without much effort. If you aren't going think about things and pursue a few ideas while you code, how much fun can it be to do? Is that why product managers need clown suits?

To me I get that same blank paper feeling when starting a project, and tough I don't start coding without planning, I try to never lose site of the fact that I'm making something the way I (or we) think it should go. It that sense to me it is just the same as making art, and sure there is less wiggle room in the last stages of a painting than the first, but it still is (or should be) a creative process at that point I think. I guess that is what I think of when talking about art and code...


PS Is it ok to drink while operating visual studio?

Robin Debreuil
Monday, August 12, 2002

Software is that mix of craft and art. There is a large amount of creativity. Especially during the design phase.

Good discipline, and good design eventually results in the most freedom to express ones self. Years of hard practice to play a instrument means one is free to play music well.

Don't anyone ever think that the issue of creativity is at odds, or against the concept of discipline. It is great discipline that un-locks one to true freedom!

With good design documents and approaches, one is free to create! I hate to say it, but some music theory helps!

Now, if any you creative people can come up with a way for me to get into the zone, maybe I can get my stalled project going again instead of visiting this site!

Any hints as to how to get back into the zone? What do you all do to get UN-stalled.

I am taking offers as to what you do when software OR music gets stuck? I am probably the only software developer that does not play music. However, I do have a feel, and sympathy for the music process, as it has many similarities to software. I am sure any thing that music people to do that gets them un-stuck will help me!

Anyway....HELP!...I am stuck and can’t get up! (or how does that commercial go?).

Suggestions welcome. Any idea!!!

(perhaps some one can start a new post title):

“I am to get going?”

(in fact, I will start a new thread...).

Albert D. Kallal
Edmonton, Alberta Canada

Albert D. Kallal
Monday, August 12, 2002

I think that Dan appropriately applied Occam's Razor to the problem at hand.  I'll take mine simple.  Thanks.

Nat Ersoz
Monday, August 12, 2002

I'm soon having a friend join my company, and I'm incidentally taking care of most of his salary.  Mainly because passion is important, and the company doesn't have the kind I want.  It's easy to joke about passion, downplay it, but sometimes it rears its heads and you know how needed it is.

Finding passion for programming was the single hardest thing about it.  It was a dull world.  Then I found SICP, and only then could I understand why anyone would do it just for the love.  I no longer needed to pretend to be a programmer (this is easy -- just type what a programmer would type), but just be myself, thinking I'm reading a story but actually writing it as I go along.

I probably rolled my eyes when I read SICP's preface, where it talked about magic words.  But it's an apt metaphor.  Language is about stringing words together.  One word in front of another.  But it eventually becomes more than that.  And our words make things happen even if no one's around to hear them.

Now, big spells, little spells.. I don't care.  I just try not to program in COBOL if I can avoid it.  I don't need to charge a lot for what I know, or make a guild so that people can't join my little club.  Maybe we are in a Renaissance.

Monday, August 12, 2002

Somewhat related:

Leonardo Herrera
Monday, August 12, 2002

I think this is one of those conversations that would benefit from a common language.

What is art?

Once you can answer that, you can determine whether music or programming is art. Otherwise, you might as well ask yourself if they're paisley as well - what paisley means in the context of programming and music is completely subjective.
Tuesday, August 13, 2002

Do not drink while operating Visual Studio.  I say again Do not drink while operating Visual Studio. 

Thursday, August 15, 2002

*  Recent Topics

*  Fog Creek Home