numerodix wrote an entry about programmers expeding lots of effort for seemingly odd reasons, and mentioned me as an example. So I'm kind of proud. It's a good post and I think the quotation he posted from The Mythical Man Month is largely accurate.
But I disagree that programming isn't art. Of course not all code is art. Probably most isn't. Sloppy get-the-job-done code written by someone who's doing it for a paycheck, without passion, is probably not art. Any more than a mass-produced badly-rendered copy of the Last Supper is art. But I think good code can be art.
Of course it's hard to define "art". One definition (yes I looked up "art" in the dictionary; yes I'm a nerd) is something "beautiful, appealing, or of more than ordinary significance". That's as good a definition as any, so let's run with it.
Code can be beautiful. There is a regularity and symmetry about good code that can invoke an emotional response in people who really understand it. Code is often talked about in aesthetic terms, and I don't think that's an accident. What word do people often use to describe good code? "Elegant". Bad code? "Ugly".
We often talk of a programmer's coding "style", as though we're reading poetry. Some people take this idea literally.
I think code can easily be something "of more than ordinary significance". Sure, a program is in the end something that's designed to be used as a tool. But the same can be said for example about buildings, and architecture is considered art by many. Something can be functional and still be art.
On those rare occassions when I produce good code, I do feel like I'm doing more than pushing buttons on a keyboard. I'm creating something unique. There is an element of emotional fulfillment when I happen upon a simple, elegant solution to a complex problem. There is the joy of having created something, something which is wholy mine, a product of my mind, and having that in front of me in a form in which it can be shared with other people.