点击此处查看视频:http://v.douyin.com/RCY8GD/
import turtle as t
t.setup(450,300)
t.pensize(4)
t.color('black')
'衣服身子'
t.speed(1)
t.fillcolor('#808080')
t.begin_fill()
t.goto(-70,30)
t.right(180)
t.circle(5,180)
t.right(180)
t.circle(10,180)
t.right(180)
t.circle(5,180)
t.end_fill() t.speed(10)
t.fillcolor('#7D916F')
t.begin_fill()
t.goto(15,0)
t.left(45)
t.fd(10)
t.right(90)
t.circle(5)
t.fd(5)
t.right(20)
t.fd(5)
t.right(40)
t.fd(10)
t.right(50)
t.fd(20)
t.left(60)
t.fd(10)
t.right(80)
t.fd(70)
t.right(90)
t.fd(25)
t.end_fill() '外侧头发' t.penup()
t.goto(10,80)
t.pendown()
t.fillcolor('#2A3025')
t.begin_fill()
t.circle(5,150)
t.right(150)
t.circle(5,150)
t.right(150)
t.circle(5,120)
t.right(100)
t.circle(5,120)
t.right(100)
t.circle(5,120)
t.right(90)
t.circle(5,120)
t.right(150)
t.circle(5,120)
t.right(90)
t.circle(5,120)
t.right(100)
t.circle(5,120)
t.right(90)
t.circle(5,120)
t.right(150)
t.circle(5,120)
t.right(90)
t.circle(5,120)
t.right(100)
t.circle(10,90)
t.fd(7)
t.end_fill() '内测头发' t.penup()
t.goto(10,80)
t.pendown()
t.fillcolor('white')
t.begin_fill()
t.goto(10,76)
t.right(150)
t.fd(10)
t.circle(20,50)
t.right(30)
t.fd(5)
t.left(60)
t.fd(10)
t.right(60)
t.fd(5)
t.left(70)
t.fd(19)
t.right(60)
t.fd(3)
t.right(60)
t.fd(3)
t.circle(10,200)
t.end_fill() '鼻子'
t.penup()
t.goto(10,76)
t.pendown()
t.fillcolor('white')
t.begin_fill()
t.goto(17,76)
t.right(45)
t.fd(2)
t.right(45)
t.fd(5)
t.left(90)
t.fd(10)
t.right(90)
t.fd(8)
t.right(80)
t.fd(13) '嘴'
t.left(150)
t.fd(10)
t.fillcolor('white')
t.end_fill() '热狗'
t.fillcolor('#FF8247')
t.begin_fill()
t.left(35)
t.fd(40)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.left(5)
t.fd(40)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.right(30)
t.fd(9)
t.end_fill() '眼睛'
t.penup() t.pensize(2) t.goto(0,70)
t.pendown() t.goto(-4,70)
t.goto(-8,68)
t.penup()
t.goto(-5,60)
t.pendown()
t.circle(1,360)
t.goto(-5,60)
t.pendown()
t.circle(2,360) t.penup()
t.goto(100,-20)
t.pendown()

turtle画王思聪吃热狗(杨艳春,何金凝小组)的更多相关文章

  1. 使用turtle画故宫(伍奇,侯俊豪小组)

    这个代码主要有两个部分,第一部分是画出故宫,第二部分是用random函数随机画心,故宫部分设置多个函数和循环再进行颜色填充即可完成. 此处为视频链接 from turtle import* impor ...

  2. python运用turtle 画出汉诺塔搬运过程

    python运用turtle 画出汉诺塔搬运过程 1.打开 IDLE 点击File-New File 新建立一个py文件 2.向py文件中输入如下代码 import turtle class Stac ...

  3. python3 turtle 画国际象棋棋盘

    python3 turtle 画国际象棋棋盘 #!/usr/bin/env python # -*- coding:utf-8 -*- # Author:Hiuhung Wan import turt ...

  4. day 03 turtle 画鹅

    turtle 画鹅 import turtle t=turtle turtle.speed(10) t. setup(800,600) #画头 turtle.penup() turtle.goto(0 ...

  5. *【Python】【demo实验31】【练习实例】【使用turtle画小猪佩奇】

    如下图小猪佩奇: 要求使用turtle画小猪佩奇: 源码: # encoding=utf-8 # -*- coding: UTF-8 -*- # 使用turtle画小猪佩奇 from turtle i ...

  6. 【Python】【demo实验29】【练习实例】【使用turtle画五角星】

    原题: 使用turtle画五角星: 我的代码: #!/usr/bin/python # encoding=utf-8 # -*- coding: UTF-8 -*- from turtle impor ...

  7. 用python turtle画玫瑰

    1.turtle 库 2.画玫瑰的代码: import turtle turtle.penup() turtle.left() turtle.fd() turtle.pendown() turtle. ...

  8. Python之turtle画同心圆和棋盘

    画饼图 import turtle t = turtle.Pen() for i in range(5): t.penup() t.goto(0, -i*30) t.pendown() t.circl ...

  9. 用python的turtle画分形树

    由于分形树具有对称性,自相似性,所以我们可以用递归来完成绘制.只要确定开始树枝长.每层树枝的减短长度和树枝分叉的角度,我们就可以把分形树画出来啦!! 代码如下: # -*- coding: utf-8 ...

随机推荐

  1. (87)Wangdao.com第二十天_JavaScript document 节点对象

    document 节点对象, 代表整个文档,每张网页都有自己的 document 对象. window.document 当浏览器开始加载文档时就存在了 正常的网页使用 document 或者 win ...

  2. Snackbar 提醒

    类似于Toast,属于design包,不要忘记导入design package com.xiaozhuyisheng.jinjiedemos.activity; import android.supp ...

  3. duilib 新增数据迁移界面

    xml界面配置: <?xml version="1.0" encoding="utf-8"?> <Window caption="0 ...

  4. java基础 第六章课后习题

    1.说明循环结构中break语句和continue语句的区别. 在循环结构中 break语句 是结束程序运行. continue语句是结束本句程序  不是结束程序. 2.使用for循环结构实现,从键盘 ...

  5. openlayers3 基础(常见方法,类及实现)

    ol3接口大全1.ol.Map类:(地图容器类) 实现: ol.Map(参数) 参数说明:1.1 target,说明地图所在的html元素. 如果没有指定,必须调用ol.Map类的setTarget( ...

  6. PL-SVO公式推导及代码解析:位姿优化

    通过跳过极线约束单独优化图像中每个特征的位置后,必须通过最小化3D特征与图像中相应的2D特征位置之间的重投影误差来进一步细化(3)中获得的相机姿态( 见图5).为此,我们考虑在世界坐标系中3D特征和相 ...

  7. CMC+混频v103测试(scrt,vbs文件)

    Sub Main Dim cnte Dim cnt Dim delay Dim time Dim onetime onetime = 9999999 delay = 5000 time = 700 F ...

  8. 简述移动端开发前端和app间的关系

    <p>前端页面嵌套进app内部,一般有时候会进行一些交互,类似于前端页面请求后台接口一样,通常会起一个前端开发人员和app开发人员会相互协定一个协议;双方就协议而言去进行请求接口和返回数据 ...

  9. Kafka: Exactly-once Semantics

    https://www.confluent.io/blog/enabling-exactly-kafka-streams/ https://cwiki.apache.org/confluence/di ...

  10. iTerm2 与 Oh My Zsh的配套使用

    详见: https://www.jianshu.com/p/7de00c73a2bb https://github.com/sirius1024/iterm2-with-oh-my-zsh https ...