4 ms·
Your point about amortization is good. Insertion mid-list is just splice with a singleton; I don't bother mentioning it separately. Those really are the only
by jemfinch 16y ago
Your point about amortization is good.
Insertion mid-list is just splice with a singleton; I don't bother mentioning it separately.
Those really are the only two advantages of linked lists over growable arrays.
- jedbrown 16y agoOkay, how about removal mid-list with an iterator? Technically that could also be called "splice" after taking sublists, but that makes the term so broad as to be almost useless.