场景
BigIntegerMath/LongMath/IntMath
demo
package com.nio4444.demo;
import com.google.common.math.BigIntegerMath;
import com.google.common.math.IntMath;
import com.google.common.math.LongMath;
import java.math.BigInteger;
import java.math.RoundingMode;
public class IntMathDemo {
public static void main(String[] args) {
System.out.println(BigIntegerMath.divide(BigInteger.TEN, new BigInteger("2"), RoundingMode.UNNECESSARY));
System.out.println( LongMath.divide(343,22, RoundingMode.FLOOR)) ;
IntMath.checkedAdd(2000000000,999999999) ;
}
}