in reply to Remove duplicate strings from an array
And this function preserves the order in the array (which the hash-based solutions don't).use List::MoreUtils qw(uniq); my @x = uniq 1, 1, 2, 2, 3, 5, 3, 4; # returns 1 2 3 5 4
CountZero
"If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law
|
|---|