in reply to Re^2: Keeping order, no duplicate and the complete keyset
in thread Keeping order, no duplicate and the complete keyset
Agreed. Your version can be simplified a little though.
my @big = qw( a b c d e f g h i a ); my @small = qw(f c d g c); my %seen; my @wanted = grep{ !$seen{ $_ }++ } @small, @big; print "@wanted"; f c d g a b e h i
|
|---|