def f(x): return 3*x+1 def suite_recurrente(f,debut,fin,u_p): u=u_p for i in range(debut,fin): u=f(u) return u