Epigrams on Programming

在新浪微博上翻程序员幽默,看到这么一条:
如果你给别人讲解程序时,看到对方点头了,那你就拍他一下,他肯定睡觉了。 ——Alan Perlis
哈哈一笑后不确定其真实性,怕又是微博上常见的 原创+名字=名言。搜索了一下Alan Perlis,图灵奖的第一位获奖人,发现程序员的幽默确实古已有之:
1982年,退休后的Alan Perlis返老还童,写下了名文“Epigrams on Programming”,发表在ACM的SIGPLAN期刊上。其中包含130条编程箴言,可能是被引用最广泛的计算机文章之一。
Alan Perlis为名著《计算机程序的构造和解释》所写的序中写道,如果说艺术解释了我们的梦想,那么计算机就是以程序的名义执行着它们。计算机科学中特别重要的一点是保持趣味性,不要局限于眼前,应该不断寻找新方向,扩展计算机的能力。
一周后是Perlis先生逝世11周年的日子,这位可爱的先生致敬!
以下为部分摘录~
Epigrams on Programming
Alan J. Perlis, Yale, September 1980
1. One man’s constant is another man’s variable.
7. It is easier to write an incorrect program than understand a correct one.
17. If a listener nods his head when you’re explaining your program, wake him up.
20. Wherever there is modularity there is the potential for misunderstanding: Hiding information implies a need to check communication.
24. Perhaps if we wrote programs from childhood on, as adults we’d be able to read them. However, reading a program is not like reading a book, it is more like being a psychiatrist to a recumbent patient.
26. There will always be things we wish to say in our programs that in all languages can only be said poorly.
27. Once you understand how to write a program get someone else to write it.
40. There are two ways to write error-free programs; only the third one works.
47. As Will Rogers would have said, “There is no such thing as a free variable.”
63. When we write programs that “learn”, it turns out we do and they don’t.
71. Documentation is like term insurance: It satisfies because almost no one who subscribes to it depends on its benefits.
78. If your computer speaks English it was probably made in Japan.
79. A year spent in artificial intelligence is enough to make one believe in God.
101. Dealing with failure is easy: Work hard to improve. Success is also easy to handle: You’ve solved the wrong problem. Work hard to improve.
112. The proof of a system’s value is its existence.
124. You think you know when you learn, are more sure when you can write, even more when you teach, but certain when you can program.
125. It goes against the grain of modern education to teach children to program. What fun is there in making plans, acquiring discipline in organizing thoughs, devoting attention to detail and learning to be self-critical?
128. Adapting old programs to fit new machines usually means adapting new machines to behave like old ones.
130. The last epigram? Neither eat nor drink them, snuff epigrams.

Today on history:

  1. 2008:  年末翻箱倒柜(10)
  2. 2006:  感慨一下(3)
此条目发表在 它山之玉 分类目录,贴了 标签。将固定链接加入收藏夹。

没有评论

(Required)
(Required, will not be published)

CommentLuv badge