OFFSET
3,1
LINKS
Karl-Heinz Hofmann, Table of n, a(n) for n = 3..10000
EXAMPLE
PROG
(PARI) a375753(n) = my(t=n*(n+1)/2, s=sqrtint(t)); t-precprime(s)^2
(Python)
from sympy import prevprime, integer_nthroot
def A375753(n): return (t:=n*(n+1)//2) - prevprime(integer_nthroot(t, 2)[0]+1)**2
# Karl-Heinz Hofmann, Aug 27 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Hugo Pfoertner, Aug 26 2024
STATUS
approved