One thing that came to my mind is why don't you combine the two steps? So you'd end up w/ something like this:
my($self) = @_; my(%seen, %r); my @common = qw(a and at); @seen{@common} = (); for my $r (@words) { next if exists $seen{ lc $r }; $r{lc $r} = 1; } my @words = sort keys %r;
In reply to Re: List processing performance
by btrott
in thread List processing performance
by Odud
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |