Java BigInteger add() Method

The add() method of Java BigInteger class is used to add two BigInteger values. This method returns a BigInteger object whose value is (this+ val).

Syntax:

Parameter:

val - A value to be added to this BigInteger.

Returns

This method returns a BigInteger object of value, this+val.

Example

Test it Now

Output:

Result of addition is 10000000000000001

Next TopicJava BigInteger




Latest Courses