my $has_date = grep /d/ + /a/ + /t/ + /e/ >= 3 , @words; my $has_publish = grep /p/+/u/+/b/+/l/+/i/+/c/+/a/+/t/+/o/+/n/ >= 8 , @words;