Skip to main content

An interval set utility library.

Project description

intervalpy

Tests

An interval set utility library.

Installation

With poetry:

poetry add intervalpy

Or with pip:

pip3 install intervalpy

Usage

Have a look at the documentation.

Basic usage:

from interval_util import Interval

digits = Interval(0, 10, end_open=True)
ten_and_up = digits.get_gt()
positive_numbers = digits.get_gte()
assert ten_and_up.is_subset_of(positive_numbers)

assert positive_numbers.intersection(Interval.lt(10)) == digits

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

intervalpy-0.1.0.tar.gz (6.3 kB view hashes)

Uploaded Source

Built Distribution

intervalpy-0.1.0-py3-none-any.whl (6.9 kB view hashes)

Uploaded Python 3

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