Public Function IsPrime( _ ByVal vNumber As Variant _ ) As Boolean
IsPrime(0) = False IsPrime(1) = False IsPrime(2) = True IsPrime(3) = True IsPrime(4) = False IsPrime(5) = True IsPrime(4.76) = True ' #7 IsPrime(-5) = True ' #8See also:
NthPrime Function NextPrime Function PreviousPrime FunctionvNumber: The number which is tested to see if it is prime. Function returns Null if vNumber is Null or cannot be fixed up to a number.
Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.