예제 #1
0
 /// <summary>
 /// Whether the current instance is prime.
 /// </summary>
 /// <param name="n">The current instance.</param>
 /// <returns>Whether the current instance is prime.</returns>
 public static bool IsPrime(this BigInteger n)
 {
     return(BagMath.IsPrime(n));
 }
예제 #2
0
 /// <summary>
 /// Whether the current instance is prime.
 /// </summary>
 /// <param name="n">The current instance.</param>
 /// <returns>Whether the current instance is prime.</returns>
 public static bool IsPrime(this long n)
 {
     return(BagMath.IsPrime(n));
 }