diff --git a/__pycache__/wordfreq.cpython-312.pyc b/__pycache__/wordfreq.cpython-312.pyc index 9345f56..6ce43f3 100644 Binary files a/__pycache__/wordfreq.cpython-312.pyc and b/__pycache__/wordfreq.cpython-312.pyc differ diff --git a/wordfreq.py b/wordfreq.py index c2b5016..5e19758 100644 --- a/wordfreq.py +++ b/wordfreq.py @@ -24,7 +24,7 @@ def tokenize(lines: list[str]) -> list[str]: for line in lines: word_type = CharType.NONE current_word = [] - for i, char in enumerate(line.lower()): + for i, char in enumerate(line.strip().lower()): if len(current_word) == 0: ct = char_type(char) if ct == CharType.SPACE: