OFFSET
1,1
COMMENTS
Indices of the primes listed in A031936.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..10300
FORMULA
MATHEMATICA
Select[Range[1700], Prime[#] + 18 == Prime[# + 1] &] (* Vincenzo Librandi, Mar 22 2019 *)
Flatten[Position[Differences[Prime[Range[2000]]], 18]] (* Harvey P. Dale, May 12 2022 *)
PROG
(PARI) A(N=100, g=18, p=2, i=primepi(p)-1, L=List())={forprime(q=1+p, , i++; if(p+g==p=q, listput(L, i); N--||break)); Vec(L)} \\ returns the list of first N terms of the sequence
(Magma) [n: n in [1..1700] | NthPrime(n+1) - NthPrime(n) eq 18]; // Vincenzo Librandi, Mar 22 2019
CROSSREFS
KEYWORD
nonn
AUTHOR
M. F. Hasler, Oct 19 2018
STATUS
approved