Skip to main content

A SICP'ish functional pairs implemented in Python

Project description

hexlet-pairs

A SICP'ish Functional Pairs implemented in Python.

Usage

>>> from hexlet import pairs
>>> p = pairs.cons(42, 'foo')
>>> pairs.is_pair(p)
True
>>> pairs.car(p)
42
>>> pairs.cdr(p)
'foo'
>>> print(pairs.to_string(p))
(42, 'foo')

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

hexlet-pairs-0.1.2.tar.gz (2.3 kB view hashes)

Uploaded Source

Built Distribution

hexlet_pairs-0.1.2-py3-none-any.whl (2.4 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