猫史档案馆


【Python作品分享】国旗【作品秀】

用户:乐乐OvO乐乐OvO查看:0 回复:1 评论:0 创建时间:2021-10-13T21:41:08


【作品展示】

center_image

 

【作品介绍】

国旗

 

【作品源代码】

import turtle as t
t.fillcolor('red')
t.begin_fill()
t.goto(0, 192)
t.goto(288,192)
t.goto(288,0)
t.goto(0,0)
t.end_fill()
t.penup()
t.goto(10,135)
t.pendown()
t.pencolor('yellow')
t.fillcolor('yellow')
t.begin_fill()
for x in range(0, 5):
    t.forward(50)
    t.right(144)
t.end_fill()
t.fillcolor('yellow')
t.begin_fill()
t.penup()
t.goto(70, 172)
t.pendown()
t.right(30)
for x in range(0, 5):
    t.forward(20)
    t.right(144)
t.end_fill()
t.fillcolor('yellow')
t.begin_fill()
t.penup()
t.goto(90, 152)
t.pendown()
t.right(30)
for x in range(0, 5):
    t.forward(20)
    t.right(144)
t.end_fill()
t.fillcolor('yellow')
t.begin_fill()
t.penup()
t.goto(80, 112)
t.pendown()
t.right(-60)
for x in range(0, 5):
    t.forward(20)
    t.right(144)
t.end_fill()
t.fillcolor('yellow')
t.begin_fill()
t.penup()
t.goto(70, 92)
t.pendown()
t.right(30)
for x in range(0, 5):
    t.forward(20)
    t.right(144)
t.end_fill()
t.hideturtle()
t.done()

 

【提示】

部分含有Python第三方库相关内容的作品,在海龟编辑器网页端无法运行哦!如遇到这种情况,可以打开下面的链接,下载海龟编辑器客户端:

https://python.codemao.cn


回复

上一页1 页 / 共 1下一页
乐乐OvO乐乐OvO

图片随便找的

 

点赞0


评论