Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Popular Words by cactusson
def popular_words(text: str, words: list) -> dict:
result = {word: 0 for word in words}
for word in text.split():
if word.lower() in result:
result[word.lower()] += 1
return result
April 9, 2020