I have a file containing a Persian sentence, a tab and then an English word. I have to delete stop words and punctuation in the file. I wrote the code in python 3, but because in some words the punctuation attaches to the word, and it is counted as a part of the word and not punctuation, it can't be deleted. So I need to use regular expression to delete stop words. I tried to use that in the code below, but I couldn't. How can I change the code below that it works correctly? (in fact, what should I write exactly?) thanks.

More Vahideh Torabi's questions See All
Similar questions and discussions