Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #17 Mar 09 2020 12:27:07
%S 2,29,229,2999,22229,0,2222929,22229299,222229229,2222229299,
%T 22222229299,0,2222222229229,22222222222229,222222222229229,
%U 2222222222229299,22222222222922299,0,2222222222222292929
%N Smallest n-digit prime containing only digits 2 and 9, or 0 if no such prime exists.
%C a(6k) = 0 as any 6k-digit number containing only digits 2 or 9 is divisible by 7. - _Jinyuan Wang_, Mar 09 2020
%H Jinyuan Wang, <a href="/A036939/b036939.txt">Table of n, a(n) for n = 1..500</a>
%t Join[{2},Table[Min[Select[FromDigits/@(Join[#,{9}]&/@Tuples[{2,9},n]), IntegerLength[#]==n+1&&PrimeQ[#]&]],{n,20}]]/.\[Infinity]->0 (* _Harvey P. Dale_, Nov 08 2011 *)
%Y Cf. A020460, A036229, A036313.
%K nonn,base
%O 1,1
%A _Patrick De Geest_, Jan 04 1999