GMPY2 jest Prime

gmpy2.is_prime(var)
#must have gmpy2 installed and imported
Lucas Gomes