cheran-senthil / cheran-senthil/PyRival

Add interval container

Open
#104 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
1.3k
Forks
307
PR merge metrics
No merged PRs in 30d

Description

It would be nice to have a class such as:

```python3
class IntervalContainer:
def __init__(self):
self.intervals = []

def add(self, interval):
...
```

```python3
intervals = Intervals()
for interval in [(0, 1), (3, 4), (7, 8), (1, 5)]:
intervals.add(interval)

print(self.intervals)
# Output: [(0, 5), (7, 8)]
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.