Should I have any performance concerns with the index position used to
pop() values off of large lists?
In other words, should pop(0) and pop() be time equivalent operations
with long lists?
--
https://mail.python.org/mailman/listinfo/python-list
On 2014-06-22 19:03, pyt...@bdurham.com wrote:
Should I have any performance concerns with the index position used
to pop() values off of large lists?
In other words, should pop(0) and pop() be time equivalent operations
with long lists?
When an item is popped from a list, all of the later
On 6/22/2014 2:03 PM, pyt...@bdurham.com wrote:
Should I have any performance concerns with the index position used to
pop() values off of large lists?
Yes. While performance is generally not part of the language
specification, in CPython seq.pop(i) is O(len(seq)-i)
In other words, should
On 06/22/2014 11:03 AM, pyt...@bdurham.com wrote:
Should I have any performance concerns with the index position used
to pop() values off of large lists? In other words, should pop(0) and
pop() be time equivalent operations with long lists?
I believe lists are optimized for adding and
MRAB, Terry, Ethan, and others ...
Thank you - collections.deque is exactly what I was looking for.
Malcolm
--
https://mail.python.org/mailman/listinfo/python-list