🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

fcompop

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fcompop

Function composition operators for functional programming

0.3
PyPI
Maintainers
1

fcompop is a Python library that provides function composition operators.

An example of usages is following:

>>> import fcompop
>>> fcompop.inject()  # adding operators to builtin&user functions
>>> func = str._ >> (lambda x: x * 2 + 'abc') >> str.upper
>>> func(123)
'123123ABC'
>>> func = (lambda x: '-' + x)._ << chr << (lambda x: x + 1) << ord
>>> func('a')
'-b'

Keywords

function composition operator functional programming

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts