. 1 Private static String STRs (String STR) { 2 IF ( "." Str.indexOf ()> 0 ) { . 3 STR = str.replaceAll ( "0 + $?", ""); // delete the mantissa is 0 character . 4 STR = str.replaceAll ( "$ [.]", ""); // end if the decimal point, then remove . 5 } . 6 return STR; . 7 // the TODO Auto-Generated Method Stub . 8 }