Public class numberic {
Public static void main (string [] ARGs ){
Printnumtochinese (11123167345786l );
}
Private Static void printnumunit (INT digit ){
String [] num_unit = {"10 "};
If (digit % 8 = 0 & digit! = 0)
System. Out. Print (num_unit [4]);
If (digit-4) % 8 = 0 & digit % 8! = 0)
System. Out. Print (num_unit [3]);
If (digit-3) % 4 = 0)
System. Out. Print (num_unit [2]);
If (digit-2) % 4 = 0)
System. Out. Print (num_unit [1]);
If (digit-1) % 4 = 0)
System. Out. Print (num_unit [0]);
}
Private Static void printnumtochinese (long num ){
String [] chs_num = {"0", "1", "2", "3", "4", "5", "6", "7 ", "8", "9", "10 "};
Boolean flag = true; // do you want to add tens of thousands of characters to the standard 0.2 billion 0 seven hundred and eighty and 0.2 billion 3,000,780
For (INT I = string. valueof (Num). Length ()-1; I> = 0; I --){
Int n = (INT) (Num/Math. Pow (10, I ));
If (num = 0)
Break;
If (n! = 0)
System. Out. Print (chs_num [N]);
If (n! = 0 ){
Printnumunit (I );
}
Num = num-N * (long) math. Pow (10, I );
If (n = 0 & I-string. valueof (Num). Length ()> = 4)
Flag = false;
If (I % 4 = 0 & n = 0 & flag ){
Printnumunit (I );
Flag = true;
}
If (I-string. valueof (Num). Length () = 0 & n = 0 ){
System. Out. Print (chs_num [N]);
}
}
}
}