cheran-senthil / cheran-senthil/PyRival
Add interval container
Open
- 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.