itertools operations on infinite generators.
Project description
Description
Some of the itertools operations do not work on infinite generators, this package is the beginning of the work to port some of the iterator concepts to the infinity.
infinite is compatible with both python2 and python3.
Installation
The package has been uploaded to PyPI, so you can install the package using pip:
pip install infinite
Usage
For example if we want to iterate all the pairs of natural numbers:
from itertools import count
from infinite import product
for x, y in product(count(0), count(0)):
print(x, y)
if (x, y) == (3, 3):
break
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
infinite-0.1.tar.gz
(1.8 kB
view details)
File details
Details for the file infinite-0.1.tar.gz
.
File metadata
- Download URL: infinite-0.1.tar.gz
- Upload date:
- Size: 1.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 23d9e850bd8101acccb2406ae81c5c0777627ae908352a3a0c2b0fc088d80cb3 |
|
MD5 | c8216a887dd236461402d2a21e5abb93 |
|
BLAKE2b-256 | 9fa731edff0e96132d1daf9c1bc7d20eacfaf98da32458ad636b1b1ce520f881 |