%I #40 Nov 08 2023 11:21:46
%S 2,1,1,2,1,0,1,2,1,1,2,2,1,0,1,2,1,1,2,2,2,1,1,2,2,1,1,2,2,2,1,1,2,2,
%T 2,2,2,2,2,1,0,1,1,1,2,2,2,2,2,2,2,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,
%U 1,1,2,2,2,2,2,2,1,1,2,2,2,2,2,2,1,1,2
%N In the pair (A246655(n), A246655(n+1)), how many primes are there?
%C First 0 terms appear at n = 6, 14, 41, 359, 3589, corresponding to consecutive prime powers (8,9), (25,27), (121,125), (2187,2197) and (32761,32768), respectively (cf. A068315 and A068435).
%H Michael De Vlieger, <a href="/A366835/b366835.txt">Table of n, a(n) for n = 1..10000</a>
%H Michael De Vlieger, <a href="/A366835/a366835.png">1038 X 1038 raster of a(n)</a>, n = 1..1077444, read left to right in rows, then top to bottom, showing a(n) = 0 in white, a(n) = 1 in red, and a(n) = 2 in dark blue.
%e a(1) = 2 because in the first prime power pair (2 and 3) there are two primes.
%e a(14) = 0 because in the 14th prime power pair (25 and 27) there are no primes.
%t With[{upto=500},Map[Count[#,_?PrimeQ]&,Partition[Select[Range[upto],PrimePowerQ],2,1]]] (* Considers prime powers up to 500 *)
%o (PARI) lista(nn) = my(v=[p| p <- [1..nn], isprimepower(p)]); vector(#v-1, k, isprime(v[k]) + isprime(v[k+1])); \\ _Michel Marcus_, Oct 26 2023
%Y Cf. A000040, A068315, A068435, A246655, A362965, A366833.
%K nonn
%O 1,1
%A _Paolo Xausa_, Oct 25 2023