static char q[7] = {' ', 'K', 'M', 'G', 'T', 'P', 'E'};
inline const char* CC_ITOA_M(long v){
long t=v;
if(t>=1000000){
//int tail1=0; // 小数点后1位
int tail2=0; // 小数点后2位
int i=1;
int t1 = t/1000000;
while(t1>=1){
if( t1>0 && t1<1000 ){
int temp1;
if(i==1){
temp1 = t - t1 * 1000000;
//tail1 = temp1/100;
}else{
temp1 = t - t1 * 1000;
//tail1 = temp1/100;
}
tail2 = (temp1 - tail2 * 100)/10;
}
t=t1;
t1 = t1/1000;
i++;
}
return CCString::createWithFormat( "%d.%d%c", t, //tail1,
tail2,
q[i])->getCString();
}
else{
return CC_ITOA((int)v);
}
}