2018-02-27 "Literate Programming"一书摘记之一
书到后才发现是Knuth的论文集, 第一篇就在网上: Computer programming as an art (1974). 其中"Taste and Style"(品味和风格)一节说到"好"程序的一部分要素:
...when it works correctly. Secondly, if it is easy to change, when the time for adaptation arises. Both of these goals are achieved when the program is easily readable and understandable to a person who knows the appropriate language.
很高兴看到他早就指出可读性的重要性.
不远处就是那句经典的:
Premature optimization is the root of all evil (or at least most of it) in programming.
时间有限, 就跳过了那些网上已有的论文. 如:
structured programming with goto statements (1974)
"a structured program to generate all topological sorting arrangements"
直接跳到"Literate Programming(1984)"一章. 先看最后一页(总共30+). 之后写到哪里算哪里吧.
这两句很有趣:
My hope is that the ability to make explanations more natural will cause more programmers to discover the joys of literate programming, because I believe it's quite a pleasure to combine verbal and mathematical skills; but perhaps I'm hoping for too much. ...
Perhaps we will even one day find Pulitzer prizes awarded to computer programs.
遥远地握握手. 想让程序像文章一样是个好坑, 估计个人是爬不出来了.
倒数第二页提到:
I don't believe every computer language should attempt to offer all things to all people.
WEB系统结合了TEX和Pascal, 是为当时的计算机科学家设计. 论文主体是介绍一个完整的例子(20页左右). 粗看一下WEB好像是一个类自然语言语法的语言, 编译可以生成TEX文档和Pascal源码.
待续.
2018-02-27 "Literate Programming"一书摘记之一的更多相关文章
- SAP接口编程 之 JCo3.0系列(02) : JCo Client Programming
SAP接口编程 之 JCo3.0系列(02) : JCo Client Programming 字数545 阅读52 评论0 喜欢1 JCo3.0调用SAP函数的过程 大致可以总结为以下步骤: 连接至 ...
- 文艺编程 Literate Programming
(译注:这篇文章是 Donald Knuth 一篇1983年的论文:Literate Programming 的介绍部分.有人翻译为“字面编程”,是极其错误的说法,literate 根本就没有“字面” ...
- 2018 ACM-ICPC, Syrian Collegiate Programming Contest
2018 ACM-ICPC, Syrian Collegiate Programming Contest A Hello SCPC 2018! 水题 B Binary Hamming 水题 C Por ...
- 【VSCode】Windows下VSCode编译调试c/c++【更新 2018.03.27】
--------– 2018.03.27 更新--------- 便携版已更新,点此获取便携版 已知BUG:中文目录无法正常调试 用于cpptools 0.15.0插件的配置文件更新 新的launch ...
- (寒假开黑gym)2018 ACM-ICPC, Syrian Collegiate Programming Contest(爽题)
layout: post title: (寒假开黑gym)2018 ACM-ICPC, Syrian Collegiate Programming Contest(爽题) author: " ...
- (寒假开黑gym)2018 ACM-ICPC, Syrian Collegiate Programming Contest
layout: post title: (寒假开黑gym)2018 ACM-ICPC, Syrian Collegiate Programming Contest author: "luow ...
- The 2018 ACM-ICPC Chinese Collegiate Programming Contest Moving On
Firdaws and Fatinah are living in a country with nn cities, numbered from 11 to nn.Each city has a r ...
- 2022.02.27 CF811E Vladik and Entertaining Flags
2022.02.27 CF811E Vladik and Entertaining Flags https://www.luogu.com.cn/problem/CF811E Step 1 题意 在一 ...
- 2022.02.27 CF811E Vladik and Entertaining Flags(线段树+并查集)
2022.02.27 CF811E Vladik and Entertaining Flags(线段树+并查集) https://www.luogu.com.cn/problem/CF811E Ste ...
随机推荐
- iostat 命令详解
前言 话说搞运维的人没有两把"刷子",都不好意思上服务器操作.还好,我还不是搞运维的,我一直都自诩是开发人员,奈何现在的东家运维人员"水"的一比,还要我这个自诩 ...
- 构建一个Gods Eye Android应用程序:第1部分 – 收集已安装的Android应用程序
首先问候一下我的黑客伙伴们,在之前的Introduction to Amunet 教程中,我们了解到Amunet可能是一个间谍Android应用程序. 我不浪费太多时间因而直入主题. 在本教程中,我们 ...
- Android退出所有Activity最优雅的方式
关于退出所有Activity,目前网上比较流行的方式大概有以下几种: ① 使用ActivityManager的方式: ② 自定义一个Activity集合类的方式: ③ 通过发送广播的方式: ④ 通过杀 ...
- Android数据存储之SQLite使用
SQLite是D.Richard Hipp用C语言编写的开源嵌入式数据库引擎.它支持大多数的SQL92标准,并且可以在所有主要的操作系统上运行. 在Android中创建的SQLite数据库存储在:/d ...
- JavaScript实现页面显示倒计时功能
下面是用JS中的日期函数和定时器完成的一个倒计时的例子,效果如图: 代码如下: <!DOCTYPE html> <html> <head> <title> ...
- HTML5之FileReader文件读取接口
FileReader用来把文件读入内存,并且读取文件中的数据.FileReader接口提供了一个异步API,使用该API可以在浏览器主线程中异步访问文件系统,读取文件中的数据. 1.FileReade ...
- python数据结构-数组/列表/栈/队列及实现
首先 我们要分清楚一些概念和他们之间的关系 数组(array) 表(list) 链表(linked list) 数组链表(array list) 队列(queue) 栈(stack) li ...
- python学习记录(一)
1.打印操作 >>> print('hello') hello >>> print(1+2) 3 2.字符串操作 ① ') Traceback (most rece ...
- Spark之GraphX的Graph_scala学习
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreem ...
- C#开源项目大全
C#开源项目大全 商业协作和项目管理平台-TeamLab 网络视频会议软件-VMukti 驰骋工作流程引擎-ccflow [免费]正则表达式测试工具-Regex-Tester Windows-Ph ...