in reply to extracting redundant and unique items
my @array = ('11','54','23','78','54','54','78'); my %hash; foreach $thing (@array){ #increment it in case for some reason you later want a # count of how many each are in the orig array $hash{$thing}++; } my @unique = keys %hash;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: extracting redundant and unique items
by Limbic~Region (Chancellor) on May 14, 2003 at 19:36 UTC | |
by AssFace (Pilgrim) on May 14, 2003 at 19:53 UTC |