simplify the prime number sieve implementation