Count the number of letters in each word.
Keep track of how many words of each length you find.
Look at the record you made and see how many there are of each size.
If there are more than one of any size, there are that many words with that many letters.
Essentially, you do it how you would do it on paper. This is not a difficult task; you just need to think.