Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
To get the unique elements in an array, we use the following code.
undef %saw; @saw{@in} = (); @out = sort keys %saw; # remove sort if undesired
In this code, i could not able to understand the meaning of this line, @saw{@in}=();
Could anyone give me the explanation of this line.
Edited by Arunbear: Changed title from 'need explanation', as per Monastery guidelines
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: need explanation of @foo{@bar} = (); (hash slice)
by tilly (Archbishop) on May 08, 2005 at 03:07 UTC | |
|
Re: need explanation of @foo{@bar} = (); (hash slice)
by davidrw (Prior) on May 08, 2005 at 03:20 UTC | |
|
Re: need explanation of @foo{@bar} = (); (hash slice)
by holli (Abbot) on May 08, 2005 at 06:18 UTC | |
|
Re: need explanation of @foo{@bar} = (); (hash slice)
by tlm (Prior) on May 08, 2005 at 14:00 UTC | |
by davido (Cardinal) on May 08, 2005 at 16:49 UTC | |
by tlm (Prior) on May 08, 2005 at 17:17 UTC | |
by davido (Cardinal) on May 09, 2005 at 01:52 UTC | |
by tlm (Prior) on May 09, 2005 at 02:24 UTC |