my @no_repeats = do { my %h; grep !$h{$_}++, @has_repeats };