4 ms·
Python has a linked list type (collections.deque), but their standard list type is a dynamic array/vector and so has entirely different performance characterist
by JeremyBanks 16y ago
Python has a linked list type (collections.deque), but their standard list type is a dynamic array/vector and so has entirely different performance characteristics. Treating it as a linked list could screw you. I don't think that's pedantic at all.
- nostrademons 16y ago...which is why both the Python and C++ examples used a vector. The post I was replying to said "If I want a linked list or any other common data structure in C++". The discussion is about how easy it is to use basic data types, not about what those data types are.