Generate random primes