Categories
Uncategorized

Key words in directory – Python

This script will read all the text files in a directory and output a list of all the words and how many times they apear.

Categories
Uncategorized

Substituting words with lists and dictionaries – Python

So we have the following string Except that it does not paint a good picture of Brighton, and The Man doesn’t like it. There are two things that we can do. We can substitute all the negative words with the same item using a list, or we can swap the negative words with nicer ones […]