BigInteger.sqrtAndRemainder

Returns an array of two BigIntegers containing the integer square root {@code s} of {@code this} and its remainder {@code this - s*s}, respectively.

@return an array of two BigIntegers with the integer square root at offset 0 and the remainder at offset 1 @throws ArithmeticException if {@code this} is negative. (The square root of a negative integer {@code val} is {@code (i * sqrt(-val))} where <i>i</i> is the <i>imaginary unit</i> and is equal to {@code sqrt(-1)}.) @see #sqrt()

class BigInteger
sqrtAndRemainder
()

Meta