Home » U++ Library support » U++ Core » Is there linked list in u++?
|
|
|
Re: Is there linked list in u++? [message #28712 is a reply to message #28707] |
Mon, 13 September 2010 17:40 |
|
mirek
Messages: 13975 Registered: November 2005
|
Ultimate Member |
|
|
aftershock wrote on Mon, 13 September 2010 06:09 | Why not?
It has special properlties, fastest insertion before and after an item.
Fastest deletion of an item.
If one needs that, it is the best...
|
The key question is:
Which element?
Going through the list to find the element you want to insert/remove will cost you much more time than insert/remove in Vector. (If you want to argue why, it is all about cache lines....)
The excelent usage for list, however, is in situation where objects are part of some list and insert/remove themselves (thus, no going through the list is required) or similar. However, list _container_ is absolutely unsuitable for such task.
That is why we have Link, but no List.
|
|
|
|
|
Goto Forum:
Current Time: Mon Apr 29 17:23:54 CEST 2024
Total time taken to generate the page: 0.02596 seconds
|