T1-统计数字问题
#include <iostream>
#include <string>
#include <assert.h>
#include <math.h>
using namespace std;
void statistic(int n, int bit, int a[]) {
if(bit>0) {
int b=bit-1, high, last, c, i;
high = n / round(pow(10,b));
last = n % (int)round(pow(10,b-1));
c = high * b * round(pow(10,b-1));
for(i=0; i<10; i++) {
a[i] += c;
}
for(i=0; i<high; i++) {
a[i] += round(pow(10,b));
}
a[high] += (last+1);
statistic(last, b, a);
}
}
void del_zero(int bit, int a[]) {
int c_zero = 0;
for(int i=bit; i>0; i--)
c_zero = c_zero +