crisp
is a programming language based on Lisp that takes more inspiration
from Rust (keywords for instance).
>> "Hello, world!"
"Hello, world!"
>> (+ 1 2 3 4 5)
15
>> (* 4 5 6)
120
>> (- 5 15)
-10
>> (* 13 (+ 1 2 3) 5)
390
>> (let x 10)
nil
>> (let y 15)
nil
>> (+ x y)
25
>> (let triple (fn (x) (* x 3)))
nil
>> (triple 5)
15
Above can also be written like so:
>> (let (triple x) (* x 3))
nil
>> (triple 5)
15
Functions can also be recursive (tail-call optimization is implemented):
>> (let (sum x acc) (if (> x 0) (sum (- x 1) (+ acc x)) acc))
nil
>> (sum 10 0)
55