OFFSET
0,2
COMMENTS
For n > 2, a(n) is in {1, 3, 7, 9}.
FORMULA
a(n) = prime(n)#/10 mod 10 for n > 2. - Charles R Greathouse IV, Dec 03 2024
MATHEMATICA
Do[p = Product[Prime[m], {m, 1, n}]; While[Mod[p, 10] == 0, p = p/10]; Print[Mod[p, 10]], {n, 0, 100}]
PROG
(PARI) a(n)=if(n<3, return([1, 2, 6][n+1])); my(m=Mod(3, 10)); forprime(p=7, prime(n), m*=p); lift(m) \\ Charles R Greathouse IV, Dec 03 2024
CROSSREFS
KEYWORD
easy,nonn,base,changed
AUTHOR
Robert G. Wilson v, Jul 28 2000
STATUS
approved