login
a(n) is the smallest number k such that k! contains k exactly n times.
0

%I #14 Jan 17 2023 07:12:52

%S 0,1,37,313,80,99,586,743,5972,9253,8736,9789

%N a(n) is the smallest number k such that k! contains k exactly n times.

%C Any further terms have k > 52000. - _Sean A. Irvine_, Jan 16 2023

%e a(3)=313 because in 313! 313 appears exactly 3 times.

%t a = Table[ -1, {12}]; Do[b = Length[ StringPosition[ ToString[n! ], ToString[n]]]; If[a[[b+1]] == -1, a[[b+1]] = n]], {n, 0, 15000} ]; a

%Y Cf. A067109.

%K nonn,base,more,less

%O 0,3

%A _Michel ten Voorde_, May 22 2001

%E More terms from _Robert G. Wilson v_, Jan 09 2002