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 A033860 #15 Jan 15 2024 15:10:50 %S A033860 1,2,4,8,16,32,55,110,121,233,466,932,1171,2288,4576,9143,10492,11741, %T A033860 22888,45776,91453,104912,116161,227327,449704,494183,628672,855350, %U A033860 890908,899807,978706,1046495,1191064,1302533,1425868,2671556,3927223,6150602,6163168 %N A033860 Sort-then-add sequence: a(n+1) = a(n) + sort(a(n)). %H A033860 Reinhard Zumkeller, <a href="/A033860/b033860.txt">Table of n, a(n) for n = 1..10000</a> %F A033860 a(n+1) = A070196(a(n)). - _Reinhard Zumkeller_, Apr 03 2015 %e A033860 After 9143 the next term is 9143 + 1349 = 10492. %p A033860 a:= proc(n) option remember; `if`(n=1, 1, (t-> %p A033860 t+parse(cat(sort(convert(t, base, 10))[])))(a(n-1))) %p A033860 end: %p A033860 seq(a(n), n=1..40); # _Alois P. Heinz_, Jan 15 2024 %t A033860 NestList[#+FromDigits[Sort[IntegerDigits[#]]]&,1,40] (* _Harvey P. Dale_, Jul 24 2016 *) %o A033860 (Haskell) %o A033860 a033860 n = a033860_list !! (n-1) %o A033860 a033860_list = iterate a070196 1 %o A033860 -- _Reinhard Zumkeller_, Apr 03 2015 %o A033860 (Python) %o A033860 from itertools import islice %o A033860 def agen(an=1): # generator of terms %o A033860 while True: yield an; an = an + int("".join(sorted(str(an)))) %o A033860 print(list(islice(agen(), 100))) # _Michael S. Branicky_, Jan 15 2024 %Y A033860 Cf. A070196, A004185. %K A033860 nonn,base %O A033860 1,2 %A A033860 _David W. Wilson_