OFFSET
0,4
COMMENTS
a(n) is well defined as the squares are alternatingly odd and even and thus the average of two successive squares is not an integer and thus no integer is equidistant to two successive squares. - Chai Wah Wu, Jul 24 2015
FORMULA
a(n) = A055227(n)^2.
EXAMPLE
6! = 720. The nearest perfect square is 729.
PROG
(PARI) a(n)=round(sqrt(n!))^2 \\ Charles R Greathouse IV, Jul 23 2015
(Python)
from gmpy2 import isqrt
A260373_list, g = [1], 1
for i in range(1, 101):
....g *= i
....s = isqrt(g)
....t = s**2
....A260373_list.append(int(t if g-t-s <= 0 else t+2*s+1)) # Chai Wah Wu, Jul 23 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved