[Python-Dev] deque alternative (original) (raw)
"Martin v. Löwis" martin at v.loewis.de
Wed Dec 28 11:55:31 CET 2005
- Previous message: [Python-Dev] deque alternative (was: Linked lists)
- Next message: [Python-Dev] deque alternative
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Tim Peters wrote:
You seem to be ignoring possiblities for sharing across lists, and such sharing is natural in many graph algorithms.
No doubt cons cells are a useful construct. I think Martin Blais (and others) advocated a plain list container type, only implemented as a linked list, instead of a as a vector. The subject is "deque alternative", after all.
Typically, you either have sharing, or you have appending, but not both. If sharing is what you want, 2-tuples (pairs) provide an adequate API (IMO). If you want a deque alternative, sharing won't happen.
Regards, Martin
- Previous message: [Python-Dev] deque alternative (was: Linked lists)
- Next message: [Python-Dev] deque alternative
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]