cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A060713 Smallest number whose sum of digits is 5^n.

This page as a plain text file.
%I A060713 #17 Dec 08 2024 12:26:53
%S A060713 1,5,799,89999999999999,
%T A060713 4999999999999999999999999999999999999999999999999999999999999999999999
%N A060713 Smallest number whose sum of digits is 5^n.
%H A060713 Harry J. Smith, <a href="/A060713/b060713.txt">Table of n, a(n) for n = 0..5</a>
%F A060713 a(n) = A051885(5^n).
%t A060713 Do[ a = {}; While[ Apply[ Plus, a ] + 9 < 5^n, a = Append[ a, 9 ] ]; If[ Apply[ Plus, a ] != 5^n, a = Prepend[ a, 5^n - Apply[ Plus, a ] ] ]; Print[ FromDigits[ a ] ], {n, 1, 4} ]
%o A060713 (PARI) a(n)={ my(s=5^n, x=s\9, d=s-9*x); (d+1)*10^x - 1 } \\ _Harry J. Smith_, Jul 10 2009
%Y A060713 Cf. A051885, A060712.
%K A060713 nonn,base
%O A060713 0,2
%A A060713 _Robert G. Wilson v_, Apr 21 2001