answersLogoWhite

0

Here's a start

umbers=[True]*5001

index=2

primes=[]

while index<5000:

multiplier=2

while index*multiplier <= 5000:

Numbers[index*multiplier]=False

multiplier+=1

index+=1

while Numbers[index]==False and index < 5000:

index+=1

for x in range(0,5000):

if Numbers[x]==True:

primes.append(x)

x+=1

print primes

User Avatar

Wiki User

14y ago

Still curious? Ask our experts.

Chat with our AI personalities

RossRoss
Every question is just a happy little opportunity.
Chat with Ross
BeauBeau
You're doing better than you think!
Chat with Beau
ProfessorProfessor
I will give you the most educated answer.
Chat with Professor

Add your answer:

Earn +20 pts
Q: Solution to find 1000th prime number using python?
Write your answer...
Submit
Still have questions?
magnify glass
imp