Count words for patterns