qse/ase/test/lsp/t1.lsp

22 lines
447 B
Plaintext
Raw Normal View History

2005-02-05 05:18:20 +00:00
(setq x (lambda (x) (car x)))
((lambda (x) (+ x 99)) (x '(10 20 30)))
((lambda (x) ((lambda (y) (+ y 1)) x)) 10)
; lisp....
((lambda (x) ((macro (y) (+ y 1)) x)) 10)
;;;;;;;
(setq init-rand (macro (seed) (lambda () (setq seed (+ seed 1)))))
2005-09-19 16:13:18 +00:00
2005-02-05 05:18:20 +00:00
(setq init-rand (lambda (seed) (lambda () (setq seed (+ seed 1)))))
2005-09-19 16:13:18 +00:00
(setq rand (init-rand 1))
(rand)
(defun init-rand (seed) (lambda () (setq seed (+ seed 1))))
(defun rand () (init-rand 1))
2005-02-05 05:18:20 +00:00
(rand)