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 A337857 #34 Jul 24 2022 02:04:23 %S A337857 10,20,30,40,50,60,70,80,90,90,0,109,120,127,136,145,154,163,172,180, %T A337857 190,0,209,218,230,236,245,254,263,270,280,290,0,309,318,327,340,345, %U A337857 354,360,370,380,390,0,409,418,427,436,450,450,460,470,480,490,0,509,518,527,536,540 %N A337857 a(n) is the smallest positive integer m with no repeated digits such that A137564(n + m) = n, or a(n) = 0 if no m exists. %C A337857 Terms computed by _Claudio Meller_. %C A337857 We set a(n)=0 when n has repeated digits; for example, a(11) = 0, a(22) = 0, a(100) = 0, a(101) = 0, since compact(c) cannot result in such n. Is n=450 the first other number that has no solution? %H A337857 Michel Marcus, <a href="/A337857/b337857.txt">Table of n, a(n) for n = 1..449</a> %o A337857 (PARI) f(n) = {my(d=digits(n)); fromdigits(vecextract(d, vecsort(vecsort(d, , 9))))}; \\ A137564 %o A337857 isokd(m) = my(d=digits(m)); #d == #Set(d); \\ A010784 %o A337857 a(n) = my(d=digits(n)); if (#Set(d) == #d, my(m=1); while (!isokd(m) || (f(n+m) != n), m++); m); \\ _Michel Marcus_, Jan 13 2022 %o A337857 (Python) %o A337857 def has_repeated_digits(n): s = str(n); return len(s) > len(set(s)) %o A337857 def A137564(n): %o A337857 seen, out, s = set(), "", str(n) %o A337857 for d in s: %o A337857 if d not in seen: out += d; seen.add(d) %o A337857 return int(out) %o A337857 def a(n): %o A337857 if n == 0 or has_repeated_digits(n): return 0 %o A337857 m = 1 %o A337857 while has_repeated_digits(m) or A137564(n+m) != n: m += 1 %o A337857 return m %o A337857 print([a(n) for n in range(1, 61)]) # _Michael S. Branicky_, Jul 23 2022 %Y A337857 Cf. A010784, A137564. %K A337857 base,nonn %O A337857 1,1 %A A337857 _Rodolfo Kurchan_, Sep 26 2020