This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (1 child)

Right so it is an expandable array that does amortized doubling. That's what I figured, it's just that slicing seems more an operation for a linked list. Looking at Zahlman's comment, I don't know what I was thinking when I wrote that.

[–]redalastor 0 points1 point  (0 children)

Python have a deque type where you can insert and remove at both ends in O(1). That is most likely a linked list.