Fix some bugs

main
zjadzhd 2023-07-26 22:30:38 +08:00
parent c944365f6b
commit 46d0c5f030
1 changed files with 3 additions and 3 deletions

View File

@ -20,9 +20,9 @@ __all__ = ["RangeSet"]
class RangeSet(object):
"""A RangeSet represents a set of nonoverlapping ranges on the
"""A RangeSet represents a set of non-overlapping ranges on the
integers (ie, a set of integers, but efficient when the set contains
lots of runs."""
lots of runs.)"""
def __init__(self, data=None):
self.monotonic = False
@ -62,7 +62,7 @@ class RangeSet(object):
"""Parse a text string consisting of a space-separated list of
blocks and ranges, eg "10-20 30 35-40". Ranges are interpreted to
include both their ends (so the above example represents 18
individual blocks. Returns a RangeSet object.
individual blocks. Returns a RangeSet object.)
If the input has all its blocks in increasing order, then returned
RangeSet will have an extra attribute 'monotonic' that is set to