Re:C++: The Most Important Complexities
by gpderetta on Thursday November 16, 2023 @04:27AM
(#38287383)
I haven taken advantage of O(1) removal on linked lists (although typically intrusive ones, not std::list) many times, but I'm pretty sure not once I did a linear scan specifically to find the element to be removed. Typically you save the iterator on some index on insertion.
[ Parent
| on HN ]
There are no comments on this comment yet.