use Lingua::EN::StopWords qw(%StopWords); my @words = ...; # Print non-stopwords in @words print join " ", grep { !$StopWords{$_} } @words;