Skip to content

Latest commit

 

History

History
25 lines (12 loc) · 447 Bytes

Readme.md

File metadata and controls

25 lines (12 loc) · 447 Bytes

Scheme.js

A toy lisp interpreter based on lis.py.

See it in your browser: https://abstractOwl.github.io/scheme.js

Try some of these:

Simple addition:

(+ 1 1)

Conditional:

(if (< 5 10) (+ 2 3) (+ 5 8))

Defining Function:

(begin (define add (lambda (x y) (+ x y))) (add 2 3))

Factorial:

(begin (define factorial (lambda (n) (if (= n 0) 1 (* n (factorial (- n 1)))))) (factorial 10))