in reply to Re: Re: Working with arrays
in thread Working with arrays
Alright. The ordering you're getting now is alphabetical, as a result of sort keys %data.
I can't see an ordering in the series "x", "y", "a", "z". The only way I can see to do that is to define it explicitly, something like this: foreach my $key (qw(typex typey typea typez))
If there is an order to that series that I'm not seeing, you may be able to capture the logic in a custom sort function. Look up the sort docs for more info.
HTH
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re (3): Working with arrays
by kevinw (Novice) on Jul 24, 2002 at 15:52 UTC |