wink wrote:

> But its performance is poor if the number of items on a
> Queue becomes large because it is implemented using a list.

> One of the things I was thinking of was doing another implementation
> using of Queue which was based on deque.

Updating from 2.3 to something newer will fix that, of course:

$ more Queue.py

...

from collections import deque

...

class Queue:

     ...

     def _init(self, maxsize):
         self.maxsize = maxsize
         self.queue = deque()

</F>

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to