generate integers from 2 to maxValue
generate primes