%I #9 Jul 16 2022 13:12:17
%S 1,2,6,7,12,13,16,21,23,27,29,33,34,44,49,54,62,68,71,72,78,83,89,92,
%T 98,99,103,106,112,114,119,148,149,154,163,167,176,177,181,182,187,
%U 188,197,209,216,218,222,232,236,237,244,252,254,257,259,266,274,279,288,301
%N Numbers k such that 24*k+-5 are both prime.
%e 1 is a term because 24*1-5 = 19 (prime) and 24*1+5 = 29 (prime).
%p q:= n-> (t-> andmap(isprime, [t-5, t+5]))(24*n):
%p select(q, [$1..400])[]; # _Alois P. Heinz_, Jul 16 2022
%t okQ[n_]:=Module[{n24=24 n},PrimeQ[n24-5]&&PrimeQ[n24+5]]; Select[Range[500],okQ] (* _Harvey P. Dale_, Feb 16 2010 *)
%Y Cf. A000027, A000040, A172147.
%K nonn
%O 1,2
%A _Juri-Stepan Gerasimov_, Jan 26 2010
%E Sequence corrected (by deleting improper terms and adding additional terms) by _Harvey P. Dale_, Feb 16 2010