BigInteger.Addition(BigInteger, BigInteger) 运算符

定义

将两个指定的 BigInteger 对象的值相加。Adds the values of two specified BigInteger objects.

public:
 static System::Numerics::BigInteger operator +(System::Numerics::BigInteger left, System::Numerics::BigInteger right);
public static System.Numerics.BigInteger operator + (System.Numerics.BigInteger left, System.Numerics.BigInteger right);
static member ( + ) : System.Numerics.BigInteger * System.Numerics.BigInteger -> System.Numerics.BigInteger
Public Shared Operator + (left As BigInteger, right As BigInteger) As BigInteger

参数

left
BigInteger

要相加的第一个值。The first value to add.

right
BigInteger

要相加的第二个值。The second value to add.

返回

leftright 的和。The sum of left and right.

注解

Addition 方法定义 BigInteger 值的加法运算。The Addition method defines the addition operation for BigInteger values. 它可以实现如下所示的代码:It enables code such as the following:

BigInteger num1 = 1000456321;
BigInteger num2 = 90329434;
BigInteger sum = num1 + num2;
Dim num1 As BigInteger = 1000456321
Dim num2 As BigInteger = 90329434
Dim sum As BigInteger = num1 + num2

不支持自定义运算符的语言可以改为调用 Add 方法。Languages that do not support custom operators can call the Add method instead.

适用于

另请参阅