Contains composition of useful structures
Project description
Compositions
A package to introduce composable structures to python
Installation
pip install Compositions
Github Repository
Usage
from compositions.compositions import Compose
# Declare a composable function
@Compose
def f(x):
return x
# Declare a composable function
@Compose
def g(x):
return x**2 + x**3
print(g(3))
print(f(4))
# f(g(x))
print( (g*f)(3) )
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
Compositions-1.0.2.1.tar.gz
(1.7 kB
view hashes)
Built Distribution
Close
Hashes for Compositions-1.0.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 456f100e81ba07ce764e66187958bcf41acd7786cdd25574c1b0a8293c392a3f |
|
MD5 | 7d99a787cc0c40ec60fac3acf05c51ec |
|
BLAKE2b-256 | dd92e3276426d3793ff934ce9bae61b8ee609d47626ac31aa8daac8b7c26314f |