Skip to content

gpapadok/cl-scheme

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

65 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Scheme in Common Lisp

A Scheme written in Common Lisp to take advantage of the built-in tools Lisp offers to read and evaluate structured expressions. This implementation is a subset of r5rs.pdf. Tested and developed only with Steel Bank Common Lisp.

Run with:

sbcl --script run.lisp

Examples

Basic
> (+ 4 5)
9
> (cons 1 (list 2 3 4))
(1 2 3 4)
Recursion
> (define (fac n) (if (= n 1) 1 (* n (fac (- n 1)))))
FAC
> (fac 10)
3628800
Higher order functions
> (define (inc x) (+ x 1))
INC
> (reduce + 0 (filter even? (map inc '(0 1 2 3 4 5))))
12

About

Scheme implementation in Common Lisp.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published