摘要: import turtle as t t.pensize(3) t.setup(600,600,50,50) t.pencolor("yellow") t.penup() t.pendown() t.circle(80) t.right(90) t.penup() t.fd(20) t.seth(0 阅读全文
posted @ 2020-03-15 13:57 可乐配牛奶 阅读(1999) 评论(0) 推荐(0) 编辑
摘要: import turtle as t t.setup(600,600,None,None) t.pensize(5) t.penup() t.pendown() t.pencolor("red") t.circle(80) t.penup() t.pendown() t.pencolor("gree 阅读全文
posted @ 2020-03-15 13:30 可乐配牛奶 阅读(875) 评论(0) 推荐(0) 编辑
摘要: import turtle turtle.pensize(5) turtle.pencolor("yellow") turtle.fillcolor("red") turtle.begin_fill() for i in range(0,5): turtle.forward(100) turtle. 阅读全文
posted @ 2020-03-15 11:56 可乐配牛奶 阅读(188) 评论(0) 推荐(0) 编辑
摘要: 1.Python语言是通用、脚本、开源、跨平台、多模型语言。 而Python绘图:turtle库的使用 —turtle库是turtle绘图体系的python实现 —turtle绘图体系:1969诞生,主要用于程序设计入门 —turtle库是pyrhon语言的标准库之一,是入门级的图形绘制函数库 2. 阅读全文
posted @ 2020-03-14 16:05 可乐配牛奶 阅读(528) 评论(0) 推荐(0) 编辑
摘要: import turtle n = eval(input("请输入五角星的长度")) turtle.begin_fill() #开始填充颜色 i = 0 while i < 5: turtle.forward(n) turtle.right(180-36) i += 1 turtle.color(" 阅读全文
posted @ 2020-03-12 12:04 可乐配牛奶 阅读(584) 评论(0) 推荐(0) 编辑
摘要: from turtle import * color("black","red") begin_fill() pu() fd(-200) pd() seth(30) fd(300) seth(-90) fd(300) seth(150) fd(300) end_fill() pu() seth(90 阅读全文
posted @ 2020-03-12 12:02 可乐配牛奶 阅读(1174) 评论(0) 推荐(0) 编辑
摘要: import turtle as t t.setup(600, 600, None,None) t.pu() t.fd(-120) t.pensize(5) t.width(5) t.pencolor("darkgreen") t.pd() t.fd(250) t.seth(120) t.penco 阅读全文
posted @ 2020-03-12 12:00 可乐配牛奶 阅读(3394) 评论(0) 推荐(0) 编辑
摘要: 1.使用turtle库绘制红色五角星图形 import turtle n = eval(input("请输入五角星的长度")) turtle.begin_fill() #开始填充颜色 i = 0 while i < 5: turtle.forward(n) turtle.right(180-36) 阅读全文
posted @ 2020-03-12 11:56 可乐配牛奶 阅读(633) 评论(0) 推荐(0) 编辑