#NEWLINE# def test_key( ) : #NEWLINE# #INDENT# slt = SortedListWithKey ( range ( 10000 ) , key = ( lambda val : ( val % 10 ) ) ) #NEWLINE# slt . _check ( ) #NEWLINE# values = sorted ( range ( 10000 ) , key = ( lambda val : ( ( val % 10 ) , val ) ) ) #NEWLINE# assert ( slt == val ) #NEWLINE# assert all ( ( ( val in slt ) for val in range ( 10000 ) ) )