OFFSET
1,1
LINKS
Project Euler, Problem 135: Same Differences.
EXAMPLE
27 is a term since (6+2*3)^2 - (6+3)^2 - 6^2 = (20+2*7)^2 - (20+7)^2 - 20^2 = 27.
PROG
(Python)
from sympy import divisors
def isok(n):
s = 0
for d in divisors(n):
t = n // d + d
if ((q:=t >> 2) << 2) == t and q < d:
s += 1
return s > 1
print([n for n in range(1, 256) if isok(n)])
CROSSREFS
KEYWORD
nonn
AUTHOR
Darío Clavijo, Jul 12 2023
STATUS
approved