OFFSET
1,1
COMMENTS
The sequence is finite with last term a(136) = 659743821.
LINKS
Zak Seidov, Table of n, a(n) for n = 1..136
EXAMPLE
(127, 463, 859) is the least triple of 3-digit primes together using each of nine digits 1..9 exactly once. Hence a(1) = 127463859.
MATHEMATICA
fQ[n_] := Block[{d = DigitCount@ n}, And[Max@ d == 1, Last@ d == 0, Plus @@ d == 9, n == FromDigits@ Flatten[IntegerDigits /@ Select[FromDigits /@ Partition[IntegerDigits@ n, 3], PrimeQ]]]]; Select[FromDigits /@ DeleteDuplicates[Flatten /@ (Sort@ Partition[IntegerDigits@ #, 3] & /@ FromDigits /@ Permutations[Range@ 9])], fQ@ # &] (* Michael De Vlieger, Mar 15 2015 *)
pnioQ[n_]:=Module[{idn=Partition[n, 3], a, b, c}, {a, b, c}=FromDigits/@ idn; a<b<c && AllTrue[{a, b, c}, PrimeQ]]; FromDigits/@ Select[ Permutations[ Range[ 9]], pnioQ] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Oct 18 2016 *)
CROSSREFS
KEYWORD
nonn,base,fini,full
AUTHOR
Zak Seidov, Mar 15 2015
STATUS
approved