Working with BigInteger
Because the System.Numerics.BigInteger
is a new type in .NET 4.0, we spend a little time on it. BigInteger
is a value type exposed by the System.Numerics namespace and requires a reference to the System.Numerics.dll assembly. Basically it represents a signed, arbitrarily large integer number. This means that it doesn’t have minimum and maximum values, opposite of other value types such as Integer
and Long
. Instantiating a BigInteger
is easy, as you can see from the following line of code:
Dim sampleBigInteger As New System.Numerics.BigInteger
You can assign any signed number to a BigInteger
, because it has no minimum and maximum values, as demonstrated by the following code snippet:
Byte
and Long
are the smallest and ...
Get Visual Basic® 2010 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.