Problem A
Count Occurrences
Write a program that, given a string
Note that the program must be case sensitive. For example,
M appears in the string Mississippi, but m
does not.
All characters in the input and output are either a letter in the English alphabet, digit, space or punctuation.
Input
Input consists of two lines.
The first line contains the string
Output
The output should consist of
The
Sample Input 1 | Sample Output 1 |
---|---|
my dogs name is mary m |
0 10 16 |
Sample Input 2 | Sample Output 2 |
---|---|
Mississippi is in the Southeastern region of the United States. s |
2 3 5 6 13 29 61 |