answersLogoWhite

0

There is no formula which will always calculate a Prime number for you. However, there are schemes for finding all the primes. The oldest is called the Seive of Eratosthenes. To find all the prime numbers between 1 and 1000,, for example, you first go through the list crossing off every other number -- these will be all the even numbers. Then you go through the remaining list crossing off every third number. Next you go through the remaining list crossing off every 4th number. Next you go through the remaining list crossing off every n th number, where n starts at 5 and goes to 499. At that point, the numbers remaining on your list are all primes. For example to find the primes between 1 and 10: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10 1, 3, 5, 7, 9 1, 5, 7 These are the primes between 1 and 10.

User Avatar

Wiki User

16y ago

Still curious? Ask our experts.

Chat with our AI personalities

SteveSteve
Knowledge is a journey, you know? We'll get there.
Chat with Steve
DevinDevin
I've poured enough drinks to know that people don't always want advice—they just want to talk.
Chat with Devin
FranFran
I've made my fair share of mistakes, and if I can help you avoid a few, I'd sure like to try.
Chat with Fran

Add your answer:

Earn +20 pts
Q: How do you calculate a prime number?
Write your answer...
Submit
Still have questions?
magnify glass
imp