在 Python 3+ 中,我尝试运行
没有名为 "setup" 的参考。
如何在 Python 3 中使用屏幕设置?
turtle.setup(400, 500)
,但它不起作用。没有名为 "setup" 的参考。
如何在 Python 3 中使用屏幕设置?
turtle.setup(400, 500)
,但它不起作用。from turtle import *
setup(400, 500)
方案二:
import turtle
turtle.setup(400, 500)
选项三:
from turtle import Turtle, Screen
screen = Screen()
screen.setup(400, 500)