A382401 a(n) is the number formed by removing all copies of the smallest digit of n, or 0 if no digits remain.
0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 2, 3, 4, 5, 6, 7, 8, 9, 2, 2, 0, 3, 4, 5, 6, 7, 8, 9, 3, 3, 3, 0, 4, 5, 6, 7, 8, 9, 4, 4, 4, 4, 0, 5, 6, 7, 8, 9, 5, 5, 5, 5, 5, 0, 6, 7, 8, 9, 6, 6, 6, 6, 6, 6, 0, 7, 8, 9, 7, 7, 7, 7, 7, 7, 7, 0, 8, 9, 8, 8, 8, 8, 8, 8, 8, 8, 0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 0, 1, 11, 12, 13, 14, 15, 16, 17, 18, 19, 11, 0, 2, 3, 4, 5, 6, 7, 8, 9, 12
Offset: 1
Examples
a(112) = 2 (the two digits 1 are removed). a(4535) = 455 (the digit 3 is removed).
Links
- Paolo Xausa, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
A382401[n_] := FromDigits[DeleteCases[#, Min[#]]] & [IntegerDigits[n]]; Array[A382401, 120]
-
PARI
a(n) = my(d=digits(n)); fromdigits(select(x->(x!=vecmin(d)), d)); \\ Michel Marcus, Mar 24 2025
-
Python
def a(n): s = str(n) m = min(s) r = s.replace(m, "") return int(r) if r != "" else 0 print([a(n) for n in range(1, 121)]) # Michael S. Branicky, Mar 23 2025
Comments