Commit af986811 by BellCodeEditor

auto save

parent fa0dff60
Showing with 23 additions and 0 deletions
import turtle
pen = turtle.Pen()#创建画笔
# 设置画笔属性
# 画笔颜色
pen.color("red")
pen.pencolor("tomato")
# 填充颜色
pen.fillcolor("gray")
# 画笔移动速度
pen.speed(0)
# 画笔粗细
pen.pensize(2)
#画一个五角星
pen.begin_fill() #开始填充
for i in range(36):
pen.forward(200) #前进
pen.right(170) # 调整角度
pen.end_fill() #结束填充
pen.hideturtle() #隐藏画笔
turtle.done() #画布保持
\ No newline at end of file
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