Really, I just don't understand what point you are trying to make.
Perl already has functions to manipulate arrays and will do everything you need without having to write all that code. see push pop shift unshift and splice.
It's usually a mistake to mechanically translate C structures into perl, as perl has many more features available (hashes for one). It's OK to write a linked list in perl as a learning exercise but I wouldn't use it for anything serious.
In reply to Re: Data structures in Perl. A C programmer's perspective.
by RichardK
in thread Data structures in Perl. A C programmer's perspective.
by code-ninja
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |