BigInteger.Subtraction(BigInteger, BigInteger) 运算符

定义

从另一个 BigInteger 值中减去 BigInteger 值。Subtracts a BigInteger value from another BigInteger value.

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 value to subtract from (the minuend).

right
BigInteger

要减去的值(减数)。The value to subtract (the subtrahend).

返回

BigInteger

rightleft 所得的结果。The result of subtracting right from left.

注解

Subtraction 方法为 BigInteger 值定义减法运算符的运算。The Subtraction method defines the operation of the subtraction operator for BigInteger values. 它可以实现如下所示的代码:It enables code such as the following:

BigInteger num1 = 100045632194;
BigInteger num2 = 90329434;
BigInteger result = num1 - num2;
Dim num1 As BigInteger = 100045632194
Dim num2 As BigInteger = 90329434
Dim result As BigInteger = num1 - num2

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

此运算符的等效方法是 BigInteger.Subtract(BigInteger, BigInteger)The equivalent method for this operator is BigInteger.Subtract(BigInteger, BigInteger).

适用于

另请参阅