60 个倾斜的圆圈,中间有一个洞
60 tilted circles with a hole in the center
我做了一个有 60 个圆圈组成一个大圆圈的东西,但我想知道如何在中间创建一个小孔。感谢您的帮助!
What mine looks like rn
What I want it to look like
我的代码
import turtle
turtle.setup(1000,1000)
turtle.hideturtle()
turtle.speed(0)
turtle.up()
turtle.goto(0,0)
turtle.down()
n = 60
for i in range(n):
turtle.circle(200)
turtle.left(360/n)
尝试以下操作,并修改这些值。
import turtle
turtle.setup(1000,1000)
turtle.hideturtle()
turtle.speed(0)
turtle.up()
turtle.goto(0,0)
turtle.down()
n = 20
for i in range(n):
turtle.up()
turtle.backward(150)
turtle.right(15)
turtle.down()
turtle.circle(100)
turtle.up()
turtle.left(15)
turtle.forward(150)
turtle.up()
turtle.left(360/n)
我做了一个有 60 个圆圈组成一个大圆圈的东西,但我想知道如何在中间创建一个小孔。感谢您的帮助!
What mine looks like rn What I want it to look like
我的代码
import turtle
turtle.setup(1000,1000)
turtle.hideturtle()
turtle.speed(0)
turtle.up()
turtle.goto(0,0)
turtle.down()
n = 60
for i in range(n):
turtle.circle(200)
turtle.left(360/n)
尝试以下操作,并修改这些值。
import turtle
turtle.setup(1000,1000)
turtle.hideturtle()
turtle.speed(0)
turtle.up()
turtle.goto(0,0)
turtle.down()
n = 20
for i in range(n):
turtle.up()
turtle.backward(150)
turtle.right(15)
turtle.down()
turtle.circle(100)
turtle.up()
turtle.left(15)
turtle.forward(150)
turtle.up()
turtle.left(360/n)