Jump to content

Prime numbers quicky

Featured Replies

is it true that all primes end in either 1,3,7 or 9 after a while?

 

I know the 1`st few dont.

C'mon, that should be really easy to answer.

 

Any number ending with 2,4,6,8 or 0 will always be divisible by 2, and hence can't be a prime.

 

Similarly, numbers ending with 5 will always be divisible by 5.

 

That leaves numbers ending with 1,3,7 and 9.

  • Author

Good, that`s exactly what I thought too, but had to ask in case there were some Exceptions I couldn`t think of (I`m no maths Genius!).

 

Thnx :)

Try this. More challenging.

 

Of all the numbers ending with 1,3,7 or 9, which has the greatest proportion of primes?

I really want to know the answer to Dhnondy's question!

  • Author

statistically the number 1 as a digit occurs in more numbers than any of the other 9 digits.

 

I would write a program to find the answer to this question but since I`m writing on an old BBC Micro it may be a little difficult to parse and each line to do so will make it even slower running than it already is.

Archived

This topic is now archived and is closed to further replies.

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.