1 class C: 2 def f(self): 3 return f 4 5 def f2(self): 6 def g2(x): 7 if x <= 0: 8 return x 9 return g2(x - 1) + x 10 return g2 11 12 def f(): 13 def g(x): 14 if x <= 0: 15 return x 16 return g(x - 1) + x 17 return g 18 19 a = f() 20 b = a(3) 21 c = C() 22 c.f() 23 d = c.f2() 24 e = d(3)