A package for all those who love the number 3.
Project description
three.py
A package dedicated to the love of 3.
This is silly personal project inspired by the equally silly JavaScript library five.js by Jack Clark.
How to install
pip install love-three
Usage examples
Begin by importing the three module into your code.
>>> import three
The module can be used to perform:
arithmetic
>>> three.three() + three.three()
6
>>> three.squared()
9
>>> three.cubed()
27
boolean expressions
>>> a = 2
>>> if three.is_three(a):
... print("a equals three :)")
... else:
... print("a does not equal three :(")
...
a does not equal three :(
filter, map, and reduce
>>> values = [1, None, 3, "beans", False, 3]
>>> three.filter(values)
[3, 3]
>>> three.map(values)
[3, 3, 3, 3, 3, 3]
>>> three.reduce(values)
3
novelty and humor
>>> three.leches()
['Condensed', 'Evaporated', 'Heavy cream']
>>> three.stooges()
['Larry', 'Curly', 'Moe']
Development setup
All the code needed is contained within:
three.py
How to contribute
Contributions are encouraged and welcomed!
- Fork the repo
- Create a branch for your new feature (
git checkout -b feature/my-cool-feature
) - Commit your changes (
git commit -am feature/my-cool-feature
) - Push to the branch (
git push origin feature/my-cool-feature
) - Create a new Pull Request
Meta
Distributed under the MIT license. See LICENSE.txt for more information.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
love-three-1.1.0.tar.gz
(4.5 kB
view hashes)
Built Distribution
Close
Hashes for love_three-1.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 80b0ca9b2fa12634c61ff453ab5e375908bd2280ffd44fc1ba9b9a8f5eb0ad80 |
|
MD5 | bf5cf9e28dd148da02ae0d7aa3ac1536 |
|
BLAKE2b-256 | 14f1fca2c3da40ec66d41de794dafbfa400d5c9cac881da06eb06e1fc2b14c71 |