This should work in the newer Perls:
my @unique = keys { map { $_ => 1 } @array }; [download]
In reply to Re: keys with an expression by hdb in thread keys with an expression by morgon