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.

A033863 Least number of Sort-then-add persistence n.

Original entry on oeis.org

1, 10, 65, 64, 175, 98, 240, 325, 302, 387, 198, 180, 550, 806, 855, 486, 351, 315, 944, 2428, 2204, 3172, 1793, 1316, 937, 2775, 1815, 1461, 2541, 9378, 13327, 9638, 8149, 6581, 46965, 23487, 12198, 10599, 10920, 52345, 48788, 180666, 174870, 291119, 155563, 915443
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Python
    from itertools import count, islice
    def agen(LIMIT):
        adict, n = dict(), 0
        for k in count(1):
            c, m = 0, k
            while c <= LIMIT and m != (s:=int("".join(sorted(str(m))))):
                m += s; c += 1
            if c not in adict:
                adict[c] = k
                while n in adict and n <= LIMIT: yield adict[n]; n += 1
                if n > LIMIT: return
    print(list(agen(40))) # Michael S. Branicky, Jan 16 2024

Extensions

a(44)-a(45) from Sean A. Irvine, Jul 26 2020