[Python-Dev] binary trees. Review obmalloc.c
"Martin v. Löwis"
martin at v.loewis.de
Sat May 6 08:20:26 CEST 2006
Vladimir 'Yu' Stepanov wrote:
> Yes. I understood it when resulted a set example.
>> However, as I just said, people usually don't remove items from
>> just-sorted lists, they tend to iterate over them via 'for i in list:' .
>>
> Such problem arises at creation of the list of timers.
For a list of timers/timeout events, a priority queue is often the best
data structure, which is already available through the heapq module.
Regards,
Martin
More information about the Python-Dev
mailing list