Skip to content

Commit

Permalink
Create 13.4.6 Word Counts
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeHS-Solutions authored Feb 16, 2024
1 parent 56c3c92 commit 4ad81c3
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
text = input("Enter a paragraph of text: ")
text = text.split()

text_dictionary = {}
for word in text:
if word in text_dictionary:
text_dictionary[word] += 1
else:
text_dictionary[word] = 1
print(text_dictionary)

0 comments on commit 4ad81c3

Please sign in to comment.