注:
使用python 3.11版本
使用windows10系统操作
请将隐藏已知文件夹后缀,关掉
公式:
from * import *
for函数使用
开始写:
新建一个.txt文件,名字Square_Screw
填入
from turtle import *
pensize(3)
bgcolor('black')
colormode(255)
pencolor((51,204,120))
for i in range(100):
fd(i + (i*2))
right(90)
hideturtle()
done()
ctrl+s保存之后,将文件后缀.txt变更为.py
右键
Eit with IDLE调出调试窗口
然后鼠标移至上方【Run】 点击Run Module(也可以直接按F5)
进入调试