All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Numbers
The number p (Posted on 2012-08-19) Difficulty: 3 of 5
Find the smallest number p such that p, p+2, p+6, p+8, p+30, p+32, p+36, and p+38 are all prime.

No Solution Yet Submitted by Math Man    
Rating: 4.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer solution Comment 1 of 1

   10   while Found=0
   20   P=nxtprm(P)
   30   if P+2=prmdiv(P+2) then
   40    :if P+6=prmdiv(P+6) then
   50    :if P+8=prmdiv(P+8) then
   60    :if P+30=prmdiv(P+30) then
   70    :if P+32=prmdiv(P+32) then
   80    :if P+36=prmdiv(P+36) then
   90    :if P+38=prmdiv(P+38) then
  100    :print P;P+2;P+6;P+8;P+30;P+32;P+36;P+38
  110      :Found=1
  120   wend

finds

 1006301  1006303  1006307  1006309  1006331  1006333  1006337  1006339
 
so the number p is 1,006,301. The other numbers are the primes that qualify p as the answer.


  Posted by Charlie on 2012-08-19 15:52:08
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (14)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information