package com.chen.test;
public class TestChinese {
public static void main(String[] args) {
System.out.println(daxie_bf(2111112.91));
//输出结果-->贰佰壹拾壹万壹仟壹佰壹拾贰元玖角壹分
}
public static String daxie_bf(double amount){
boolean negative = false;
if (amount < 0.0D){
negative = true;
amount *= -1D;
}
long temp = Math.round(amount * 100D);
int numFen = (int)(temp % 10L);
temp /= 10L;
int numJiao = (int)(temp % 10L);
temp /= 10L;
int parts[] = new int[20];
int numParts = 0;
for (int i = 0; temp != 0L; i++){
int part = (int)(temp % 10000L);
parts[i] = part;
numParts++;
temp /= 10000L;
}
boolean beforeWanIsZero = true;