Python编出爱心的方法:

from turtle import *
pensize(1)
pencolor('red')
fillcolor('pink')
speed(5)
up()
goto(-30, 100)
down()
begin_fill()
left(90)
circle(120,180)
circle(360,70)
left(38)
circle(360,70)
circle(120,180)
end_fill()
up()
goto(-100,-100)
down()
登录后复制

84c27af3bf4e4a9b1bfbed62f431a6e.png

以上就是Python如何编出爱心的详细内容,更多请关注悠悠之家其它相关文章!

点赞(32)

评论列表共有 0 条评论

立即
投稿
返回
顶部