def __init__(self, iterable=None, key=identity, load=1000):
        """
        SortedListWithKey provides most of the same methods as a list but
        keeps the items in sorted order.

        An optional *iterable* provides an initial series of items to populate
        the SortedListWithKey.

        An optional *key* argument defines a callable that, like the `key`
        argument to Python's `sorted` function, extracts a comparison key from
        each element. The default is the identity function.

        An optional *load* specifies the load-factor of the list. The default
        load factor of '1000' works well for lists from tens to tens of millions
        of elements.  Good practice is to use a value that is the cube root of
        the list size.  With billions of elements, the best load factor depends
        on your usage.  It's best to leave the load factor at the default until
        you start benchmarking.
        """
        self._len, self._maxes, self._lists, self._keys, self._index = 0, [], [], [], []
        self._key, self._load, self._twice, self._half = key, load, load * 2, load >> 1
        self._offset = 0

        if iterable is not None:
            self._update(iterable)
def __init__ ( self , iterable = None , key = identity , load = 1000 ) : self . _len , self . _maxes , self . _lists , self . _keys , self . _index = 0 , [ ] , [ ] , [ ] , [ ] self . _key , self . _load , self . _twice , self . _half = key , load , load * 2 , load >> 1 self . _offset = 0 if iterable is not None : self . _update ( iterable )
SortedListWithKey provides most of the same methods as a list but
        keeps the items in sorted order.

        An optional *iterable* provides an initial series of items to populate
        the SortedListWithKey.

        An optional *key* argument defines a callable that, like the `key`
        argument to Python's `sorted` function, extracts a comparison key from
        each element. The default is the identity function.

        An optional *load* specifies the load-factor of the list. The default
        load factor of '1000' works well for lists from tens to tens of millions
        of elements.  Good practice is to use a value that is the cube root of
        the list size.  With billions of elements, the best load factor depends
        on your usage.  It's best to leave the load factor at the default until
        you start benchmarking.