Dear Tutors:
Thank you for your time.I am trying to do first assignment (ps1a+b) onMIT open
study, finding the 1000th prime in part a and doing something with import.math
and logs in part b, but I'm not there yet. The little build i did to find
primes does fine until, for some reason, 95 shows up, and later other multiples
of 5 jump into the mix without being invited.I end up almost 200 primes off by
the 1000 count. Is it me? Have uninstalled and reinstalled 2.7 twice. Here is
code:
per = 25
num = 3
yep = 0
while per > 0:
for den in range(2, num):
if num % den == 0:
num = num + 2
else: yep = (num)
print yep
per = per - 1
num = num + 2
thank you again,
M
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor