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”).

A217657
Delete the initial digit in decimal representation of n.
12
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20
OFFSET
0,13
COMMENTS
When n - a(n)*10^[log_10 n] >= 10^[(log_10 n) - 1], where [] denotes floor, or when n < 100 and 10|n, n is the concatenation of A000030(n) and a(n) - corrected by Glen Whitney, Jul 01 2022
a(110) = 10 is the first term > 9. The sequence consists of 10 repetitions of 0 (n = 0..9), then 9 repetitions of {0, ..., 9} (n = 10..99), then 9 repetitions of {0, ..., 99} (n = 100..999), and so on. - M. F. Hasler, Oct 18 2017
LINKS
FORMULA
a(n) = 0 if n <= 9, otherwise 10*a(floor(n/10)) + n mod 10.
a(n) = n mod 10^floor(log_10(n)), a(0) = 0. - M. F. Hasler, Oct 18 2017
MATHEMATICA
Array[FromDigits@ Rest@ IntegerDigits@ # &, 121, 0] (* Michael De Vlieger, Dec 22 2019 *)
PROG
(Haskell)
a217657 n | n <= 9 = 0
| otherwise = 10 * a217657 n' + m where (n', m) = divMod n 10
(PARI) apply( A217657(n)=n%10^logint(n+!n, 10), [0..199]) \\ M. F. Hasler, Oct 18 2017, edited Dec 22 2019
(Python)
def a(n): return 0 if n < 10 else int(str(n)[1:])
print([a(n) for n in range(121)]) # Michael S. Branicky, Jul 01 2022
CROSSREFS
Cf. A059995 (drop final digit of n), A000030 (initial digit of n), A202262.
Sequence in context: A118943 A010879 A179636 * A175419 A175422 A175423
KEYWORD
nonn,base,look
AUTHOR
Reinhard Zumkeller, Oct 10 2012
EXTENSIONS
Data extended to include the first terms larger than 9, by M. F. Hasler, Dec 22 2019
STATUS
approved