OFFSET
1,2
LINKS
Daniel Lignon, Table of n, a(n) for n = 1..74
EXAMPLE
108 is in this sequence because the number of composite numbers which can be obtained by permuting some or all of digits of 108 is larger than the number of composite numbers obtainable in the same way for any smaller integer. With 108, you can form 9 composite numbers: 8, 10, 18, 80, 81, 108, 180, 801, 810. It's impossible to form n >= 9 composite numbers in the same way with any integer < 108.
MATHEMATICA
f[n_] := Length[Union[ Select[FromDigits /@ Flatten[Permutations /@ Subsets[IntegerDigits[n]], 1], CompositeQ]]];
d=-1; res={}; Do[b=f[n]; If[b>d, AppendTo[res, n]; d=b], {n, 10000}]; res
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Daniel Lignon, Apr 19 2019
STATUS
approved