in reply to Re^2: finding the first unique element in an array
in thread finding the first unique element in an array
But unless I'm mistaking something obvious your code won't work as you're populating %seen withmy %seen; for (0..$#name1) { next if $seen{ $name1[$_] }++; print $name2[$_]; }
.( 0 => 1, ..., $#name1 => 1 )
|
|---|