OFFSET
3,1
LINKS
Chai Wah Wu, Table of n, a(n) for n = 3..2308
MAPLE
b:= proc(n) option remember; `if`(n=0, 1, ilcm(n, b(n-1))) end:
a:= n-> prevprime(b(n)):
seq(a(n), n=3..30); # Alois P. Heinz, Feb 17 2024
MATHEMATICA
Table[NextPrime[LCM@@Range[n], -1], {n, 3, 30}] (* Harvey P. Dale, May 28 2014 *)
PROG
(PARI) a(n) = precprime(lcm([1..n])); \\ Michel Marcus, Mar 18 2018
(Python)
from sympy import prevprime, lcm
def A060358(n):
return prevprime(lcm(range(1, n+1))) # Chai Wah Wu, Jan 22 2020
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Apr 01 2001
STATUS
approved