OFFSET
1,2
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..10000 (first 1000 terms from Harry J. Smith)
EXAMPLE
a(49) = (4+9)*(4*9) = 13*36 = 458.
MAPLE
a:= n-> (l-> add(i, i=l)*mul(`if`(i=0, 1, i), i=l))(convert(n, base, 10)):
seq(a(n), n=1..100); # Alois P. Heinz, Jun 29 2018
MATHEMATICA
psd[n_]:=Module[{idnx0=Select[IntegerDigits[n], #>0&]}, Times@@idnx0 Total[idnx0]]
psd/@Range[90] (* Harvey P. Dale, Feb 24 2011 *)
Array[Times @@ DeleteCases[#, 0]*Total@ # &@ IntegerDigits[#] &, 65] (* Michael De Vlieger, Jun 29 2018 *)
PROG
(PARI) a(n) = sumdigits(n) * vecprod(select(t->t, digits(n))) \\ Harry J. Smith, Aug 05 2009
CROSSREFS
KEYWORD
nonn,easy,base,changed
AUTHOR
Amarnath Murthy, Jun 21 2001
EXTENSIONS
More terms from Larry Reeves (larryr(AT)acm.org), Jun 22 2001
STATUS
approved