words ['the','cat','sat','on','the','mat'counts {start with an empty dictionary for word in wordswork through all the words do something we start by creating an empty dictionary it' empty because we haven' read any words yet then we loop through the list of words using standard for loop for each word we have to do something to increment the count in the dictionary