标签:alt for nbsp got fill 图片 def black png
from turtle import *
def square(size=50):
pencolor(‘orange‘)
for i in range(4):
fd(size)
left(90)
def main():
setup(800,600)
speed(0)
for i in range(10):
square(80)
left(36)
hideturtle()
done()
if __name__==‘__main__‘:
main()
from turtle import *
setup(800,600)
pencolor(‘pink‘)
for i in range(10):
for i in range(2):
circle(80,90)
left(90)
right(36)
hideturtle()
done()
from turtle import *
speed(0)
setup(800,600)
bgcolor(‘black‘)
pencolor(‘white‘)
angle=0
size=2
for i in range(10):
for j in range(4):
fd(size)
angle=angle+72
seth(angle)
size=size+5
hideturtle()
done()
from turtle import*
from random import random
def rect(x,y):
fd(x)
left(90)
fd(y)
left(90)
fd(x)
left(90)
fd(y)
def moveto(x,y):
penup()
goto(x,y)
pendown()
for i in range(20,220,20):
moveto(i,0)
left(90)
rgb=tuple(random()for i in range(3))
color(rgb)
begin_fill()
rect(100,20)
end_fill()
hideturtle()
done()
标签:alt for nbsp got fill 图片 def black png
原文地址:https://www.cnblogs.com/yy2dd/p/14875969.html