Re: perlfaq4: How can I remove duplicate elements from a list or array?
[email protected] (_brian_d_foy) Fri, 01 Apr 2005 13:22:47 -0600
| Newsgroups | perl.perlfaq.workers |
|---|---|
| Message-ID | <010420051322478254%[email protected]> |
In article <[email protected]>, Steven Schubiger <[email protected]> wrote: > On 31 Mar, _brian_d_foy wrote: > > : my @unique = grep { ! $Seen{ $elem }++ } @array; > > Shouldn't it read $Seen{ $_ } instead? Indeed it should be. Thanks :) -- brian d foy, [email protected]