in reply to Linked list in Perl
A linked-list is a specific implementation of “a list,” but Perl already has well-defined List and Array data-types. You don’t need to bother to create your own ... unless you are dealing with a very unusual edge-case, for which there will undoubtedly be an application-specific module to be found at http://search.cpan.org.
If you find yourself “dumpster diving” to details at that level, it almost invariably means that you are on the wrong track. (Heck, that’s also true with C++, which has plenty of “extensible container” classes available off-the-shelf.) It means that you are getting lost in one path of “how can I do this” and losing sight of “what am I trying to achieve?” (A very easy thing to do!)
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Linked list in Perl
by Anonymous Monk on Sep 29, 2012 at 09:36 UTC |