OFFSET
0,13
COMMENTS
Equivalently, write n in base 10, multiply the last digit by the number with its last digit removed.
The first 100 terms coincide with those of A035930 (maximal product of any two numbers whose concatenation is n), A171765 (product of digits of n, or 0 for n<10), A257297 ((initial digit of n)*(n with initial digit removed)), but the sequence is of course different from each of these three.
The terms a(10) - a(100) also coincide with those of A007954 (product of decimal digits of n).
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,-1).
FORMULA
a(n) = 2*a(n-10)-a(n-20). - Colin Barker, May 11 2015
G.f.: x^11*(9*x^8+8*x^7+7*x^6+6*x^5+5*x^4+4*x^3+3*x^2+2*x+1) / ((x-1)^2*(x+1)^2*(x^4-x^3+x^2-x+1)^2*(x^4+x^3+x^2+x+1)^2). - Colin Barker, May 11 2015
MATHEMATICA
Table[Floor[n/10] Mod[n, 10], {n, 100}] (* Vincenzo Librandi, May 11 2015 *)
PROG
(PARI) a(n, b=10)=(n=divrem(n, b))[1]*n[2]
(Magma) [Floor(n/10)*(n mod 10): n in [0..100]]; // Vincenzo Librandi, May 11 2015
(Python) def A257850(n): return n//10*(n%10) # M. F. Hasler, Sep 01 2021
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
M. F. Hasler, May 10 2015
STATUS
approved