Question 902616
That depends on the asymptotic runtime of your prime-checking algorithm, and you would also need a ton of space.


By the way, 15 seconds to check all primes up to 100000 seems pretty slow. I was able to create a list of primes up to 100000 in about 0.5 sec. Here is some example Python code:

def prime(n): #this one is on Wikipedia
___if n < 1: return False
___if not n%2 or not n%3: return False

___for i in xrange(5, int(n**0.5 + 1), 6):
______if not n%i  or not n%(i+2): return False
___return True


Then to generate a list of primes:
def primeslist(n): #creates a list of primes <= n:
___l = []
___for i in range(1, n+1):
______if prime(i): l.append(i)
___return l

Of course there are faster methods but it only took 0.5 seconds to create the list.