My turtle module does not work in IDE. Can anyone help me?
Code:
import turtle
t = turtle.pen()
I wrote this code to make the turtle module open its app, but it didn't happen.
You have to add turtle.mainloop()
or turtle.done()
at the last of the file.
Starts event loop - calling Tkinter’s mainloop function. Must be the last statement in a turtle graphics program. Must not be used if a script is run from within IDLE in -n mode (No subprocess) - for interactive use of turtle graphics.
You can read turtle document for more details.