Minimal lisp interpreter in Lua. Trying to make one of these from time to time. It’s very simplistic, ineficient and not even very lispish.
- (define (fib x) (if (= x 1) 1 (* x (fib (- x 1))))) (fib 10) => 3628800
- (define foo (lambda (x) (+ x 1))) (goo 41) => 42
- (define foo 32) (define bar (lambda (x) (+ foo x))) (bar 3) => 35 (set! foo 10) => 10 (bar 3) => 13