def __new__(cls, iterable=None, key=None):
<EOL>if key is None:<EOL><INDENT>return object.__new__(cls)<EOL><DEDENT>else:<EOL><INDENT>if cls is SortedList:<EOL><INDENT>return object.__new__(SortedListWithKey)<EOL><DEDENT>else:<EOL><INDENT>raise TypeError('<STR_LIT>')<EOL><DEDENT><DEDENT>
SortedList 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 SortedList.

An optional *key* argument will return an instance of subtype
SortedListWithKey.