from math import * def f(a, b, c, x): return a*x**2 + b*x + c def coord_entieres(a, b, c, n): for i in range(1, n + 1): if f(a, b, c, i) == floor(f(a, b, c, i)): print([ i, f(a,b,c,i)])
from math import* def indice(n): ... for i in range(n+1): u = ... if u ... 7 == 0: l.append(...) return l
Nos manuels sont collaboratifs, n'hésitez pas à nous en faire part.
Oups, une coquille
j'ai une idée !