The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A270311 Indices of primes ending with the same decimal digit as the previous or next prime. 2

%I #17 Mar 07 2024 15:40:40

%S 34,35,42,43,53,54,61,62,68,69,80,81,82,83,101,102,106,107,115,116,

%T 125,126,127,128,138,139,141,142,145,146,154,155,157,158,172,173,175,

%U 176,177,178,191,192,193,194,204,205,222,223,233,234,258,259,260,266,267,269,270,279,280,289,290,306,307

%N Indices of primes ending with the same decimal digit as the previous or next prime.

%H Harvey P. Dale, <a href="/A270311/b270311.txt">Table of n, a(n) for n = 1..1000</a>

%t Select[Range@ 307, Function[k, Or[k == Mod[NextPrime@ Prime@ #, 10], k == Mod[NextPrime[Prime@ #, -1], 10]]]@ Mod[Prime@ #, 10] &] (* _Michael De Vlieger_, Mar 15 2016 *)

%t PrimePi/@Select[Partition[Prime[Range[350]],3,1],Mod[#[[2]],10]==Mod[#[[1]],10]||Mod[#[[2]],10]==Mod[#[[3]],10]&][[;;,2]] (* _Harvey P. Dale_, Mar 07 2024 *)

%Y Cf. A270310.

%K nonn,base

%O 1,1

%A _Francois Alcover_, Mar 15 2016

%E More terms from _Michael De Vlieger_, Mar 15 2016

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 June 7 11:28 EDT 2024. Contains 373172 sequences. (Running on oeis4.)