login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A078499 Two-prime decades. 1

%I #9 Feb 05 2019 10:58:45

%S 20,30,50,60,80,150,160,170,230,250,260,270,280,330,340,350,370,380,

%T 400,440,490,500,520,540,560,570,590,600,650,670,700,730,750,760,910,

%U 940,970,990,1010,1100,1120,1150,1180,1210,1220,1230,1270,1280,1290,1320

%N Two-prime decades.

%H Robert Israel, <a href="/A078499/b078499.txt">Table of n, a(n) for n = 1..10000</a>

%p select(t -> nops(select(isprime, [t+1,t+3,t+7,t+9]))=2, [seq(i,i=10..10^4,10)]); # _Robert Israel_, Feb 05 2019

%o (PARI) decade2(n1,n2) = { if(n1==0,n1=10); forstep(x=n1,n2,10, if(isprime(x+1) && isprime(x+3) && !isprime(x+7) && !isprime(x+9), print1(x" ");); if(isprime(x+1) && isprime(x+7) && !isprime(x+3) && !isprime(x+9), print1(x" ");); if(isprime(x+1) && isprime(x+9) && !isprime(x+3) && !isprime(x+7), print1(x" ");); if(isprime(x+3) && isprime(x+7) && !isprime(x+1) && !isprime(x+9), print1(x" ");); if(isprime(x+3) && isprime(x+9) && !isprime(x+1) && !isprime(x+7), print1(x" ");); if(isprime(x+7) && isprime(x+9) && !isprime(x+1) && !isprime(x+3), print1(x" ");); ); }

%K easy,nonn,base

%O 1,1

%A _Cino Hilliard_, Jan 04 2003

%E Offset corrected by _Robert Israel_, Feb 05 2019

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 09:18 EDT 2024. Contains 371935 sequences. (Running on oeis4.)