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.
%I A316155 #20 Feb 16 2025 08:33:56 %S A316155 19999999999999999999999,28999999999999999999999, %T A316155 37999999999999999999999,38899999999999999999999, %U A316155 46999999999999999999999,47899999999999999999999,48889999999999999999999,55999999999999999999999,56899999999999999999999,57799999999999999999999,57889999999999999999999 %N A316155 Numbers with additive persistence = 4 and digits in nondecreasing order. %C A316155 All terms of <= 32 digits have digit sum 199. - _Robert Israel_, Jun 25 2018 %H A316155 Robert Israel, <a href="/A316155/b316155.txt">Table of n, a(n) for n = 1..10000</a> %H A316155 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/AdditivePersistence.html">Additive Persistence</a> %F A316155 A031286(a(n)) = 4. %e A316155 Repeatedly taking the sum of digits starting with 19999999999999999999999 gives 199, 19, 10 and 1. There are four steps, so the additive persistence is 4 and 19999999999999999999999 is a member. %p A316155 S:= proc(d,t,m) # d digits of sum t with max m %p A316155 option remember; %p A316155 local j; %p A316155 if d*m < t then return [] fi; %p A316155 if d = 1 then if t > 0 then return [[t]] else return [] fi fi; %p A316155 [seq(op(map(L -> [op(L),j], procname(d-1,t-j,j))),j=1..min(m,t))] %p A316155 end proc: %p A316155 seq(op(sort(map(t -> add(t[-i]*10^(i-1),i=1..nops(t)), S(d,199,9)))),d=23..24); # _Robert Israel_, Jun 25 2018 %Y A316155 Cf. A031286, A304366, A304367, A304368. %K A316155 nonn,base %O A316155 1,1 %A A316155 _Jaroslav Krizek_, Jun 25 2018