Skip to content

BigNumber.Divide Method

Definition

Namespace: Corvus.Numerics
Assembly: Corvus.Text.Json.dll
Source: BigNumber.cs

Divide(BigNumber, BigNumber, int)

Divides one BigNumber by another with specified precision.

public static BigNumber Divide(BigNumber dividend, BigNumber divisor, int precision)

Parameters

Name Type Description
dividend BigNumber The dividend.
divisor BigNumber The divisor.
precision int The number of decimal places of precision.

Returns

BigNumber

The quotient.

Exceptions

Exception Description
DivideByZeroException Thrown when divisor is zero.
ArgumentOutOfRangeException Thrown when precision is negative.

Applies To

Product Versions
.NET 9, 10
.NET Standard 2.0, 2.1

Collaborate with us on GitHub

The source for this content can be found on GitHub, where you can also create and review issues and pull requests.

Open an issue