On Sun, Mar 3, 2019 at 10:12 PM Abdur-Rahmaan Janhangeer
<arj.pyt...@gmail.com> wrote:
>
> i can be wrong but i guess that inserting at the begining does not cause 
> troubles as insertion at index 0 is constant (time does not scale with number 
> of data)
>

In a deque? Correct. But the price of that is reduced efficiency in
other areas. A Python list is *not* efficient for inserting at index
0, but is compact and fast for other, more common operations.

If you want a deque, you know where to find it. The list is not like
that though.

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to