/picolang

Minimal interpreter of functional language, writen in JavaScript

Primary LanguageJavaScriptMIT LicenseMIT

Minimal interpreter of functional language, writen in JavaScript

Write your program in file program.pls and execute node index.js.

Supports variable declaration
(foo = true)
(bar = foo)

Your program need to be writen in functional style. Example:

(a = 1000)

(b = (if true
  (a true)
  (a false)
))

(c => (if true
  (a true)
  (a false)
))

(a = false)

(log (b c))

Operators are now made:

  • if

Functions are now made:

  • plus
  • minus
  • multiplication
  • division
  • sqrt
  • pow
  • not
  • and
  • or
  • xor
  • log