MathHelper.negateExact

Returns the negation of the argument, throwing an exception if the result overflows a {@code long}.

@param a the value to negate @return the result @throws ArithmeticException if the result overflows a long

  1. int negateExact(int a)
  2. long negateExact(long a)
    class MathHelper
    static
    long
    negateExact
    (
    long a
    )

Meta