OFFSET
1,2
COMMENTS
Probably a(316) = -1.
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..315
Eric Weisstein's World of Mathematics, Sort-then-Add Sequence.
PROG
(Python)
from itertools import islice
def a(n):
while n != (s:=int("".join(sorted(str(n))))): n += s
return s
print([a(n) for n in range(1, 72)]) # Michael S. Branicky, Jan 15 2024
CROSSREFS
KEYWORD
nonn,base
AUTHOR
STATUS
approved