Live data from Hacker News

Knuth: Computer Programming as an Art (1974)

paulgraham.com

21–30 of 110 posts

Re: Knuth: Computer Programming as an Art (1974)

#21

If we define an art as strive to reach an aesthetic global optimum, by balancing form and meaning (syntax and semantics, if you wish, design and implementation) with attention to every single detail, then [some] programming is an art without a slightest doubt.

Aesthetic global optimum can never be reached as it changes with time and differs among people. We are cursed to eternally iterate over our programs in attempt to reach this lofty goal.

Let me know if you've seen any program that can be described as aesthetically optimal.

Re: Knuth: Computer Programming as an Art (1974)

#23
post #19

Earlier quoted context omitted.

Of course CS is a (formal) science.

Is it though? It can certainly be formal. But so is logic, so is mathemetics. I am not sure there is a clear consensus if math is a science. I can go with engineering (but licensed engineers might object to that), art or craft perhaps.

CS is a funny beast. It's the first time we're seriously dealing with machines executing abstract math directly. There's nothing to study via experimentation - computing is pure math, and hardware stuff is pure engineering (since computation is not tied to particular branch of physics - you can make computing run on anything, not just electrons and photons). It's best to conceptually split the two, if we want to stay with the original terminology. But I guess now it's kind of too late - it's the definition of the word 'science' that will get relaxed.

Re: Knuth: Computer Programming as an Art (1974)

#25

If we define an art as strive to reach an aesthetic global optimum, by balancing form and meaning (syntax and semantics, if you wish, design and implementation) with attention to every single detail, then [some] programming is an art without a slightest doubt.

Aesthetic global optimum can never be reached as it changes with time and differs among people. We are cursed to eternally iterate over our programs in attempt to reach this lofty goal. Let me know if you've seen any program that can be described as aesthetically optimal.

> Aesthetic global optimum can never be reached

Do you honestly think that writers, painters or composers doesn't know it, or it stopped them from striving?

Millions of little pieces - Data modules from GHC, especially logic, lists, big chunks from Erlang stdlib, lib9, libbio, libutf from Inferno, parts of various Lisps, tons of code from carefully written books (PoFAD, PAIP/ALMA, OnLisp, etc) well-crafted projects like nginx, or even something like this:

http://karma-engineering.com/lab/wiki/Bootstrapping8

[shit removed]

Re: Knuth: Computer Programming as an Art (1974)

#26
Great read. Indeed programming is not a 'gentle art', I would say it's a 'brutal art'.

There was an article outlining a continuum between art and science, where engineering was somewhere in the middle. Art is the least rigorous of them, while science has the most rigor.

Being a science enthusiast, reading on quantum physics, evolutionary biology, etc., I've learned more/less how scientists think. It has a lot to do with coming up with not only good explanations, but explanations that are extremely hard to vary. Explanations that risk falling apart if you try to change any aspect of it. This together with a mountain of evidence supporting said explanation, makes for good science.

Art on the other hand, is arguably vague by definition. Art that is doesn't leave room for interpretation is often bland. Art also has a huge human component, whereas science tries to do away with it.

In my opinion, programming can easily be both an art and a science. There's no need to constrain it to either one. On one hand, you have the mathematical theory of information, describing a hard-to-vary explanation that is backed up with great math(s). On the other, you have an infinite set of tools from which you can craft whatever your imagination is capable of coming up with. Programming, having its foundations in mathematics, leverages its infinite potential, and with it the possibility of creating both works of art, and scientific facts. It is this universe of possibility that takes only the toughest of minds to venture and explore.

Re: Knuth: Computer Programming as an Art (1974)

#27

Earlier quoted context omitted.

Aesthetic global optimum can never be reached as it changes with time and differs among people. We are cursed to eternally iterate over our programs in attempt to reach this lofty goal. Let me know if you've seen any program that can be described as aesthetically optimal.

> Aesthetic global optimum can never be reached Do you honestly think that writers, painters or composers doesn't know it, or it stopped them from striving? Millions of little pieces - Data modules from GHC, especially logic, lists, big chunks from Erlang stdlib, lib9, libbio, libutf from Inferno, parts of various Lisps, tons of code from carefully written books (PoFAD, PAIP/ALMA, OnLisp, etc) well-crafted projects l…

Dude, I wasn't even arguing with you. It's a true statement.

My response was not meant to be in opposition to yours, it's just a remark. There was no need to say that. Don't start shit. Your comment needs to be flagged.

Re: Knuth: Computer Programming as an Art (1974)

#28
On the subject of art and programming, I really like how Fred Brooks described it in "The Mythical Man-Month":

The delight of working in such a tractable medium. The programmer, like the poet, works only slightly removed from pure thought-stuff. He builds his castles in the air, from air, creating by exertion of imagination. Yet the program construct, unlike the poet’s words, is real in the sense that it moves and works, producing visible outputs separate from the construct itself.

I wrote more on this subject in "Why I Love Coding" http://henrikwarne.com/2012/06/02/why-i-love-coding/

Re: Knuth: Computer Programming as an Art (1974)

#29
post #19

Earlier quoted context omitted.

Is it though? It can certainly be formal. But so is logic, so is mathemetics. I am not sure there is a clear consensus if math is a science. I can go with engineering (but licensed engineers might object to that), art or craft perhaps.

CS is a funny beast. It's the first time we're seriously dealing with machines executing abstract math directly. There's nothing to study via experimentation - computing is pure math, and hardware stuff is pure engineering (since computation is not tied to particular branch of physics - you can make computing run on anything, not just electrons and photons). It's best to conceptually split the two, if we want to stay…

> There's nothing to study via experimentation

There isn't??

Re: Knuth: Computer Programming as an Art (1974)

#30

Art can occur when the same person is both the source of the requirements for the program, and the implementor of the program. Much of the art is in the coming up with the specification: that is the concept in the art. The concept can be skillfully rendered into code. Concept + skillful rendering = art.

> Art can occur when the same person is both the source of the requirements for the program, and the implementor of the program.

Unfortunately, that is frequently also the recipe for a big ball of mud [1]. I guess the beauty is in the eye of the beholder...

[1] http://www.laputan.org/mud/

Post reply on HN