in reply to Re^2: Array VS Linked List
in thread Array VS Linked List
The point of a linked list is to provide O(1) add and remove operations anywhere in the list, given certain assumptions. If you can do that with a Perl array (which you can), then it satisfies all the reasons why a linked list exists. The implementation of meeting those criteria is ... irrelevant.
Linked lists are, in many ways, inferior to Perl's arrays. You cannot do random access into a linked list, but you can into a Perl array.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Array VS Linked List
by salva (Canon) on Nov 16, 2007 at 19:41 UTC | |
by tye (Sage) on Nov 16, 2007 at 20:51 UTC | |
by tilly (Archbishop) on Nov 16, 2007 at 23:29 UTC | |
by dragonchild (Archbishop) on Nov 16, 2007 at 20:41 UTC | |
by tye (Sage) on Nov 16, 2007 at 20:54 UTC | |
by dragonchild (Archbishop) on Nov 16, 2007 at 21:47 UTC | |
by gleepglop (Novice) on Nov 16, 2007 at 22:41 UTC | |
|
Re^4: Array VS Linked List
by samtregar (Abbot) on Nov 16, 2007 at 19:07 UTC | |
|
Re^4: Array VS Linked List
by gamache (Friar) on Nov 16, 2007 at 18:10 UTC |