New numbers added for quick and easy reuse without struct creations.

This commit is contained in:
mlemanczyk committed 2025-12-28 00:12:39 +01:00
1 parent 6678f24887
commit 6603f65993
2 files changed
+17 -1

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
using System.Numerics;
namespace PerfectNumbers.Core
{
public static class BigIntegerNumbers
{
public static readonly BigInteger OneShiftedLeft63 = BigInteger.One << 63;
public static readonly BigInteger OneShiftedLeft256MinusOne = (BigInteger.One << 256) - BigInteger.One;
public static readonly BigInteger Two = (BigInteger)2;
public static readonly BigInteger UlongMaxValue = (BigInteger)ulong.MaxValue;
public static readonly BigInteger UlongMaxValuePlusOne = UlongMaxValue + BigInteger.One;
public static readonly BigInteger UInt128MaxValue = (BigInteger)UInt128.MaxValue;
public static readonly BigInteger UInt128MaxValuePlusOne = UInt128MaxValue + BigInteger.One;
}
}