Directory

Encyclopedia

NodeWorks
                              ENCYCLOPEDIA

Link Checker

Home
Encyclopedia : L : LA : LAZ :

Lazy K

 

Lazy K

Lazy K is a functional esoteric programming language created by Ben Rudiak-Gould. It is referentially transparent and features garbage collection and a simple stream-based I/O system. Lazy K is based on SKI combinator calculus, a derivation of Lambda calculus. This language is much more minimalistic than Unlambda, the most famous functional esoteric programming language. Compared to Unlambda's seven primitive functions, Lazy K manages with only three predefined combinators: S, K, and I. Furthermore, only primitive combinators can be called, as the programming language offers no system for defining and calling functions other than the pre-existing functions. There are no numbers, there are no strings. The only data is that which can be expressed using S, K and I. There are no side-effects. It is, nevertheless, a Turing-complete programming language. It is surprisingly capable for a language in which even numeric values must be expressed as functions in the form of Church integers.

Another unusual quality of Lazy K is its flexibility of dialect. Lazy K can be written in Lisp-like CL notation, "(K(SI(KK)))", in JOT notation, which looks like "1111100011111111100000111", or in Unlambda notation, "```sii``s``s`ks``s".

Lazy K is also surprisingly compact. A complete Unlambda interpreter written in Lazy K is ten times shorter than an equivalent Unlambda interpreter written in Unlambda.

See also

  • Lambda calculus
  • Unlambda

    External links

  • Lazy K
  • Lazy-K interpreters, compilers and sample code



  • NodeWorks boosts web surfing!
    Page Returned in 0.975 seconds - HTML Compressed 69.0%

    This article is from Wikipedia. All text is available
    under the terms of the GNU Free Documentation License.
     GNU Free Documentation License
    © 2008 Chamas Enterprises Inc.