Skip to main content

python functional utilities

Project description

import xython as xy
_ = xy._

xy.and_then(
        sum | xy.partial([]),
        sum,
        print
        )([[1, 2, 3], [2, 3, 4]])
# => print(sum(sum([[1, 2, 3], [2, 3, 4]], [])))

_*2    | xy.before_with(_ + 10) | xy.call(2)  # => (2 + 10) * 2

_ + 10 | xy.next_by(_ * 5)     | xy.call(2)   # => (2 + 10) * 5

(lambda x, y: x+y) | xy.to_curry | xy.call(1, 2)  # => 1 + 2

(lambda x, y: x+y) | xy.to_curry | xy.call(1) | xy.call(2)  # => 1 + 2

Not only the syntax sugar, JIT and AOT could be expected.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

xython_for_python-0.0.1-py3-none-any.whl (7.1 kB view details)

Uploaded Python 3

File details

Details for the file xython_for_python-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for xython_for_python-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a99430256ceef53b51f8eb5ea2f07c1d5103356c601162ec3c448f1ef2e2b18e
MD5 a6dfcd1ce4879184746eee2bf5537476
BLAKE2b-256 e1b467935e19454529a193698adb56efec3a91b59b8419c1575a5238de5a0164

See more details on using hashes here.

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