Skip to main content

REPL for the lambda calculus

Project description

lambda_repl

Tests codecov

The lambda_repl package contains a REPL for the lambda calculus.

To use it, execute lambda-repl or python3 -m lambda_repl and enter commands.

Requirements

Python >= 3.10 and the packages lambda_calculus and lark are required to use this package.

Installation

python3 -m pip install lambda-repl

Examples

python3 -m lambda_repl
Welcome to the the Lambda REPL, type 'help' for help
λ alias I = \x.x
λ alias K = λx.λy.x
λ import SUCC = lambda_calculus.terms.arithmetic.SUCCESSOR
λ aliases
I = (λx.x)
K = (λx.(λy.x))
SUCC = (λn.(λf.(λx.(f ((n f) x)))))
λ trace K a b
β ((λy.a) b)
β a
λ exit
Exiting REPL...

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lambda_repl-1.2.0.tar.gz (20.5 kB view hashes)

Uploaded Source

Built Distribution

lambda_repl-1.2.0-py3-none-any.whl (19.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page