Commit 297c4d18 by BellCodeEditor

save project

parent d252f19a
Showing with 3 additions and 2 deletions
......@@ -13,6 +13,7 @@ pen.backward(150) # 后退
pen.down()
def tree(n):
if n >= 0:
if n <= 12:
color_list = ['snow','lightcoral']
color = random.choice(color_list)
......@@ -32,8 +33,8 @@ def tree(n):
pen.up()
pen.backward(n)
pen.down()
tree(100)
turtle.done()
tree(100)
turtle.done()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment