美文网首页
我的Python蟒蛇图。

我的Python蟒蛇图。

作者: 勤学善思_ | 来源:发表于2021-08-13 18:58 被阅读0次

    #Pythondraw.py

    import turtle

    turtle.setup(650,350,200,200)

    turtle.penup()

    turtle.fd(-250)

    turtle.pendown()

    turtle.pensize(15)

    turtle.pencolor("rainbown")

    turtle.seth(-40)

    for i in range(4):

        turtle.circle(20,80)

        turtle.circle(-40,80)

    turtle.circle(40,80/2)

    turtle.fd(40)

    turtle.circle(15,180)

    turtle.fd(40*2/3)

    turtle.done()


    中国大学MOOC Python语言程序设计的主讲老师嵩天,讲课特别有趣。采用项目式教学,今天学了一下午,很有收获。希望能学成。

    编程截图

    相关文章

      网友评论

          本文标题:我的Python蟒蛇图。

          本文链接:https://www.haomeiwen.com/subject/hbdjbltx.html