This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A358690 #34 Jan 14 2023 08:44:48 %S A358690 3,12,42,125,608,2427,10081,43568,197823,873432,3978580,18159630, %T A358690 83753054,387670103,1811802273,8451565541,39790817677 %N A358690 Number of n-digit primes whose digits are all odd. %F A358690 a(n) = A358685(n) - A358685(n-1). %e A358690 a(2) = 12 as there are 12 2-digit primes whose digits are all odd: 11, 13, 17, 19, 31, 37, 53, 59, 71, 73, 79, 97. %t A358690 Length[Select[Prime[Range[PrimePi[10^(n - 1)], PrimePi[10^n]]], And @@ OddQ[IntegerDigits[#]] &]] %o A358690 (Python) %o A358690 from sympy import primerange %o A358690 def a(n): %o A358690 num=0 %o A358690 for f in range(1,10,2): %o A358690 p=list(primerange(f*10**(n-1),(f+1)*10**(n-1))) %o A358690 num+=sum(1 for k in p if all(int(d) %2 for d in str(k))) %o A358690 return(num) %o A358690 print ([a(n) for n in range(1,8)]) %o A358690 (Python) %o A358690 from sympy import isprime %o A358690 from itertools import count, islice, product %o A358690 def a(n): %o A358690 c = 0 if n > 1 else 1 %o A358690 for p in product("13579", repeat=n-1): %o A358690 s = "".join(p) %o A358690 for last in "1379": %o A358690 if isprime(int(s+last)): c += 1 %o A358690 return c %o A358690 print([a(n) for n in range(1, 10)]) # _Michael S. Branicky_, Nov 27 2022 %Y A358690 Cf. A030096, A358685. %K A358690 base,nonn,more %O A358690 1,1 %A A358690 _Zhining Yang_, Nov 26 2022 %E A358690 a(10)-a(14) from _Michael S. Branicky_, Nov 26 2022 %E A358690 a(15) from _Zhining Yang_, Dec 21 2022 %E A358690 a(16)-a(17) from _Martin Ehrenstein_, Dec 24 2022