in reply to Array of Hash interface to an Array of Array?
POE uses it.use constant name => 0; use constant age => 1; use constant height => 2; my $people = [ [ 'fred', 25, 1.5 ], [ 'sally', 20, 1.4 ], ]; for my $person( @$people ) { print $person->[name],"\n"; } __END__
| MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!" | |
| I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README). | |
| ** The third rule of perl club is a statement of fact: pod is sexy. |
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Array of Hash interface to an Array of Array?
by jaa (Friar) on Sep 01, 2003 at 14:52 UTC |