OFFSET
0,2
COMMENTS
EXAMPLE
For a(0), 3^0 = 1 with product of digits 1;
for a(3), 3^3 = 27 with product of digits 2*7 = 14;
for a(10), 3^10 = 59049 with product of digits 5*9*0*4*9 = 0.
MATHEMATICA
a[n_] := Times @@ IntegerDigits[3^n]; Array[a, 69, 0] (* Amiram Eldar, Nov 07 2022 *)
PROG
(Python)
from math import prod
def a(n): return prod(map(int, str(3**n)))
print([a(n) for n in range(69)]) # Michael S. Branicky, Nov 06 2022
(PARI) a(n) = vecprod(digits(3^n)); \\ Michel Marcus, Nov 07 2022
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Joseph Caliendo, Nov 06 2022
EXTENSIONS
More terms from Michael S. Branicky, Nov 06 2022
STATUS
approved