I can understand simple recursion, such as:
def count(n):
if n <= 0:
return
else:
print n
count(n-1)
count(3)
However, when faced with more complicated code, such as, an implementation of Koch snowflake:
def koch(order, size):
if order == 0:
t.forward(size)
else:
koch(order-1, size/3)
t.left(60)
koch(order-1, size/3)
t.right(120)
koch(order-1, size/3)
t.left(60)
koch(order-1, size/3)
koch(1, 100)
I get confused. I do not understand how to follow these multiple recursive function calls.