OFFSET
0,1
LINKS
John Cerkan, Table of n, a(n) for n = 0..10000
John Cerkan, Python 2.7
MATHEMATICA
fr[n_] := If[n == 0, {{}}, Join[{Range[9]}, Table[Range[0, 9], {n - 1}]]]; bk[n_] := If[n == 0, {{}}, Join[Table[Range[0, 9], {n - 1}], {{1, 3, 7, 9}}]]; cand[n_, f_, b_] := FromDigits /@ Partition[ Flatten[ Map[ IntegerDigits, Tuples@ DeleteCases[Join[fr[f], {{n}}, bk[b]], {}], 2]], f + b + IntegerLength@n]; a[0] = 101; a[n_] := Block[{m = Infinity, k = 0}, While[m == Infinity, k++; Do[ m = Min[m, Select[cand[n^3, f, k - f], PrimeQ]], {f, 0, k}]]; m]; Array[a, 100, 0] (* Giovanni Resta, May 11 2017 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
STATUS
approved