def bisect_right(self, val):
"""
Same as *bisect_left*, but if *val* is already present, the insertion
point will be after (to the right of) any existing entries.
"""
_maxes = self._maxes
if not _maxes:
return 0
pos = bisect_right(_maxes, val)
if pos == len(_maxes):
return self._len
idx = bisect_right(self._lists[pos], val)
return self._loc(pos, idx)
评论列表
文章目录