Skip to main content

Elementary combinators in Python inspired by LISP and Haskell. Mostly a convenience library for my sake.

Project description

combinators.py

Elementary combinators in Python inspired by LISP and Haskell. Mostly a convenience library for my sake.

Installation

pip install pycombinators

Sample Usage

from pycombinators import flip
from functools import partial

# returns true if all values in xs are numbers
def is_all_numbers(xs: list) -> bool:
    isinstanceof = flip(isinstance)
    return all(map(partial(isinstanceof, float), xs))

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

pycombinators-1.0.2.tar.gz (14.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pycombinators-1.0.2-py3-none-any.whl (14.6 kB view details)

Uploaded Python 3

File details

Details for the file pycombinators-1.0.2.tar.gz.

File metadata

  • Download URL: pycombinators-1.0.2.tar.gz
  • Upload date:
  • Size: 14.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.9

File hashes

Hashes for pycombinators-1.0.2.tar.gz
Algorithm Hash digest
SHA256 c4719559c5b915c7bb134dd0f4409068ac07e8dc21879a0ed87aa2f5c0298718
MD5 3dd80916d1c48a9f4a0a1ff45fc26ea0
BLAKE2b-256 01e8d9beea4b39ab9f79bf6dfce1dd54c19083d7516f36abd5004112f898e8c1

See more details on using hashes here.

File details

Details for the file pycombinators-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: pycombinators-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 14.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.9

File hashes

Hashes for pycombinators-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2c08abd51c5ac619c7ae31237dd86db63e8c38e81707d01a265cf34de0449217
MD5 59e81075e768a5641158fe62b571122e
BLAKE2b-256 8949c810ea7529f0687812312e4acaba43322dc1730c07a2da3f25c6285c4171

See more details on using hashes here.

Supported by

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