Help for this page

Select Code to Download


  1. or download this
    use strict;
    use Array::Utils qw(:all);
    ...
    
    __END__
    prints: e c a g b d f
    
  2. or download this
    @unique_array = keys %{{map { $_ => undef } @array }};
    
  3. or download this
    my %seen;
    @unique_array = grep { not $seen{$_}++ } @array;