Java multiplyExact() in Math
The java.lang.Math.multiplyExact() is a built-in math function in java that returns the product of the arguments.It throws an exception if the result overflows an int. As multiplyExact(int a, int b) is static, so object creation is not required. Syntax: public static int multiplyExact(int a, int b)