精确浮点数运算(包括加、减、乘、除、四舍五入)工具类
public class ArithUtil {
// 除法运算默认精度
private static final int DEF_DIV_SCALE = 10;
private ArithUtil() {
}
/**
* 精确加法
*/
public static double add(double value1, double value2) {
BigDecimal b1 ...
原创
2019-11-06 15:10:40 ·
212 阅读 ·
0 评论