go ahead... be a heretic | |
PerlMonks |
Re: Array indicesby FoxtrotUniform (Prior) |
on Sep 14, 2002 at 05:53 UTC ( [id://197805]=note: print w/replies, xml ) | Need Help?? |
I know it's a contrived example, but really, data this related should be kept in records (here, that would be hashes) rather than parallel arrays:
It really does make manipulating the data much easier. The only time that I can think of where you'd have to split related data among separate arrays is if you were doing matrix-based numerical stuff with it, and even then you're probably best off building the matrices from an intermediate (and more domain-specific) data structure. Yours in pedantry, --
In Section
Seekers of Perl Wisdom
|
|