爱上python编程没道理,苏苏老师教你学编程,简单又有趣,赶紧试试看吧!
#NiceHexSpiral.py
import turtle
colors=[‘red’,‘purple’,‘blue’,‘green’,‘yellow’,‘orange’]
t=turtle.Pen()
turtle.bgcolor(‘black’)
for x in range(100):
t.pencolor(colors[x%6])
t.width(x/100+1)
t.forward(x)
t.left(59)
t.speed(100000)
python美轮美奂的多边螺旋图

相关文章:

  • 2021-09-06
  • 2022-02-04
  • 2021-08-22
  • 2021-06-22
  • 2021-07-08
  • 2021-07-27
  • 2021-04-25
  • 2021-08-21
猜你喜欢
  • 2021-12-22
  • 2021-12-21
  • 2022-01-16
  • 2021-08-18
  • 2021-11-04
相关资源
相似解决方案