#t126. 数字出现次数统计
数字出现次数统计
Digit Frequency Counting
Problem Description
Write a program that reads an indefinite number of integers in the range , and counts how many times each digit appears. Input terminates with . At most numbers are given.
Input Format
One line containing several integers separated by spaces, terminated by .
Output Format
A total of lines. For each digit from to , output one line in the format:
数字的出现次数:次数
where 数字 is replaced by the digit and 次数 by its count.
Note: the surrounding Chinese characters must be printed exactly as shown above — the judge compares them character by character, so do not translate them in your output.
Sample Input
1 2 3 1 -1
Sample Output
0的出现次数:0
1的出现次数:2
2的出现次数:1
3的出现次数:1
4的出现次数:0
5的出现次数:0
6的出现次数:0
7的出现次数:0
8的出现次数:0
9的出现次数:0
Sample Explanation
The input numbers are , , , in order; reading stops after . Counting gives: digit appears times, digit appears time, digit appears time, and the remaining digits do not appear, so their counts are .
Constraints
The number of input integers does not exceed ; each is or an integer from to . The input is guaranteed to end with , and is not counted in the statistics.