2.9 输入输出 (Input and Output) 2.9 输入输出 (Input and Output) 到目前为止,我们已经利用顶层偷偷使用了 I/O 。对实际的交互程序来说,这似乎还是不太够。在这一节,我们来看几个输入输出的函数。 最普遍的 Common Lisp 输出函数是 format 。接受两个或两个以上的实参,第一个实参决定输出...
CDs and Records(CD 和记录) CDs and Records(CD 和记录) To keep track of CDs that need to be ripped to MP3s and which CDs should be ripped first, each record in the database will conta...
Function Composition Function Composition We have discussed how functional programs are essentially a number of functions that work together, this is called composition (functi...
The Mighty LOOP (强大的 LOOP ) The Mighty LOOP (强大的 LOOP ) For the simple cases you have DOLIST and DOTIMES . And if they don’t suit your needs, you can fall back on the complete...
Generalized Assignment(广义赋值) Generalized Assignment(广义赋值) Variable bindings, of course, aren’t the only places that can hold values. Common Lisp supports composite data structu...
零基础教程 絮叨 为什么选择 Clojure Clojure 能做什么 为什么 Clojure / Lisp 没有流行 如何部署 Clojure 运行环境 如何运行 Clojure 程序 文档 附录 零基础教程 A language that doesn’t affect the way you think about progra...
WHEN and UNLESS (WHEN 和 UNLESS ) WHEN and UNLESS (WHEN 和 UNLESS ) As you’ve already seen, the most basic form of conditional execution—if x , do y ; otherwise do z --is pro...
Function Parameter Lists Function Parameter Lists There’s not a lot more to say about function names or documentation strings, and it will take a good portion of the rest of th...