1.翻页进行 统计数字
#include <stdio.h>
#include <math.h>
int main(){
int i;
int temp;
int number = 12345;
int count[10] = {0};
for(i = 1;i <= number;i++){
temp = i;
while(temp > 0){
count[temp % 10] ++;
temp = temp / 10;
}
}
for(i = 0;i < 10;i ++){
printf("%5d\n",count[i]);
}
return 0;
}