Explore Library
Code QuizIntermediate

Removing Stopwords from Tokens

Find why this filter keeps the stopwords instead of removing them.

Codepython
words = ["this", "is", "a", "great", "movie"]
stopwords = ["this", "is", "a"]
filtered = [w for w in words if w in stopwords]
print(filtered)

What is the bug in this stopword-removal code?