Re: Hash arrays [was: does property exists in a record]
Re: Hash arrays [was: does property exists in a record]
- Subject: Re: Hash arrays [was: does property exists in a record]
- From: Shane Stanley <email@hidden>
- Date: Tue, 14 Aug 2001 11:37:16 +1000
On 14/8/01 11:26 AM +1000, Greg Strange, email@hidden,
wrote:
>
> I'd like to see some argument for why they'd
>
> improve the life of the average scripter.
>
>
Well for me in Perl, I use it a lot to do things like managing lists of
>
values under a single variable where I don't necessarily know what is going
>
to be passed to me (as in a CGI). To make myself clear let me describe it
>
like this:
>
>
If I had two guys named Ted and Arnold, I could use $key{$value} and be able
>
to manage every instance of name as essentially a nested list. Basically it
>
allows me to get in and out of deeply complex arrays faster and without as
>
much coding. It also allows me to change the name of the key of each value
>
so that if later I wanted to pass a list of first names (but keep the same
>
data), my code doesn9t change at all because it just cares about each unique
>
$key.
>
>
I am not entirely sure I make myself clear.
You lost me at the word "Perl" ;-)
Seriously, "it allows me to get in and out of deeply complex arrays faster
and without as much coding" is along the lines of what I was after --
thanks.
Sounds potentially very useful to me, but I guess I still wonder about its
priority.
--
Shane Stanley, email@hidden