错误:java.lang.arithmeticexception: non-terminating decimal expansion; no exact representa 小数位膨胀
解决方法:(截取相应的位数)
- BigDecimal result = x.divide(y, 3, BigDecimal.ROUND_HALF_UP)
错误:java.lang.arithmeticexception: non-terminating decimal expansion; no exact representa 小数位膨胀
解决方法:(截取相应的位数)