login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A330970
For any number n >= 0 with decimal digits (d_1, d_2, ..., d_k), the decimal expansion of a(n) is (n mod (1+d_1), n mod (1+d_2), ..., n mod (1+d_k)).
3
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 11, 0, 11, 4, 13, 2, 11, 0, 19, 20, 1, 11, 23, 4, 11, 25, 3, 11, 29, 20, 31, 2, 11, 24, 35, 1, 15, 22, 39, 0, 11, 20, 33, 44, 3, 14, 27, 33, 49, 20, 31, 41, 51, 4, 11, 20, 31, 44, 59, 40, 51, 62, 3, 14, 25, 33, 43, 55, 69, 60
OFFSET
0,3
LINKS
FORMULA
a(n) <= n with equality iff n belongs to A330969.
a(n) = 0 iff n belongs to A330971.
EXAMPLE
For n = 42:
- 42 mod (1+4) = 2,
- 42 mod (1+2) = 0,
- hence a(42) = 20.
PROG
(PARI) a(n) = fromdigits(apply(d -> n%(d+1), digits(n)))
CROSSREFS
Cf. A330969 (fixed points), A330971 (indices of zeros).
Sequence in context: A349278 A195833 A257294 * A139281 A059707 A256754
KEYWORD
nonn,base,look
AUTHOR
Rémy Sigrist, Jan 05 2020
STATUS
approved