| 1 | initial version |
r = 10
m = 2
def fonction_n(k):
if k == 0:
return r//m
return 10 * (fonction_n(k-1) - fonction_q(k-1) * m)
def fonction_q(k):
if k == 0:
return 0
return fonction_n(k)//m
It is possible to derecursify this functions
happy new year
Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.