CLisp
文档
ubuntu下安装clisp
sudo apt-get install clisp
创建./CLisp/test.lisp
(defun helloworld () (format t "hello world"))
(helloworld)
clisp
(load "test.lisp")
(helloworld)
或者
clisp test.lisp即可
语法知识
(terpri) 换行
eval 解释器
'string = (quote string) 标记不应该被求值的变量
cond、if
(
defun cmp (x y)
(
cond
((equal x y) '=)
((< x y) '<)
((> x y) '>)
)
)
(
if (= 1 2)
(write '=)
(write '!=)
)
本文来自博客园,作者:XDU18清欢,转载请注明原文链接:https://www.cnblogs.com/XDU-mzb/p/16068199.html
浙公网安备 33010602011771号