CodeLab Academy 📞 9936 6696
← List Python · Level 9: Functions and dicts Code · 90 points ← #800 #802 →

#801. Word count

You get a sentence. Print every different word in alphabetical order as `word count`. Use a dictionary (dict). ### Input One line. ### Output Lines.

Examples

Input
banana level apple scratch rocket scratch
Output
apple 1
banana 1
level 1
rocket 1
scratch 2
Input
banana rocket banana scratch robot planet apple planet planet scratch robot scratch
Output
apple 1
banana 2
planet 3
robot 2
rocket 1
scratch 3

💡 You can solve it with Python, JavaScript or blocks. Read the input line by line with input(). Don't print a question (like input("Number: ")). Print exactly what the output asks for, nothing more.

🔒 You can solve the first 3 problems without an account. Sign up for free to solve this one!