P21443 [HackerEarth] You will be provided with a passage (no special characters, no punctuations). Your task is to find the frequency of the words occurring in the text, in other words find the number of tim
普及-
题目描述

You will be provided with a passage (no special characters, no punctuations). Your task is to find the frequency of the words occurring in the text, in other words find the number of times a word occurs in the given passage.
Input
A string with no special characters or punctuations.

Output

Output should be in the format:

Word Count

where Word is a string in the passage, and count is an integer representing number of times the Word has appeared in the passage. Word and the count must be separated by a space.

Words and their count must be listed out in same order as given in the passage.

Passage will be given as a single string, and not in paragraphs.
Constrains

0 ≤ W ≤ 1000

where W is the number of words in the passage.
Note

strings 'apple', 'APPLE', 'Apple' are all considered to be instances of the same word 'APPLE'. In Output, all letters of the words must be converted into UPPERCASE.(Refer Sample Input/Output)

SAMPLE INPUT
My name is Xyz He is Abc Is he allright

SAMPLE OUTPUT
MY 1
NAME 1
IS 3
XYZ 1
HE 2
ABC 1
ALLRIGHT 1

Explanation

In Sample Input:

My name is Xyz He is Abc Is he allright

'My' is converted into 'MY' to find all other instances of 'My' in the passage easier. MY is present only once in the passage, so the frequency of 'MY' is 1.

'Name' is converted into 'NAME', and its frequency is 1.

'Frequency of the word 'is' is 3 ('is', 'IS', 'Is' (check passage) ). 'is' is converted into 'IS'. All instances of thee word 'IS' are found from the passage.

Similarly the counting process is done for all other words in the passage.

So the output is:

MY 1
NAME 1
IS 3
XYZ 1
HE 2
ABC 1
ALLRIGHT 1

输入格式

见题面

输出格式

见题面

样例输入
This citadel of learning stands as a guiding spirit leading to illumination of technical and intellectual acumen among the vibrant youth Within a very short span of time since its inception the missionary zeal of the institute coupled with its ardent commitment and enormous amount of compassion on student community has enabled to witness exuberant accomplishment in the realm of education by receiving a plethora of accolades and recognitions from various reputed organizations
样例输出
APPLE 1