http://qs1969.pair.com?node_id=61610


in reply to Re: Detecting duplicate entries
in thread Detecting duplicate entries

Don't assign values, just assign ().

Or use:

$seen{$_}++ or push @uniq, $_ for @orig; # or @uniq = grep !$seen{$_}++, @orig;


japhy -- Perl and Regex Hacker