Python用递归画一棵树

from turtle import *
from random import randint
def tree(d,bb):
width(10/d)
c=randint(bb//2,bb)
fd(c)
if d<8:
jd1=randint(0,30)
jd2=jd1+randint(0,30)
lt(jd1)
tree(d+1,c)
rt(jd2)
tree(d+1,c)
lt(jd2-jd1)
fd(-c)
speed(0)
lt(90)
tree(1,100)
递归树