0

import turtle screen = turtle.Screen()

screen.onclick(a.goto(-175,175))

#I was trying to make the turtle move once a clicked it with my mouse, but each time I run this code the turtle just automatically moves to that position before I can click it

  • Please format your code. See [How do I format code blocks?](https://meta.stackoverflow.com/q/251361) – user202729 Feb 12 '21 at 02:21
  • The duplicate target looks correct -- but is there one that is not closed? @TigerhawkT3 – user202729 Feb 12 '21 at 02:49
  • @user202729 - Why? It answers this question. – TigerhawkT3 Feb 12 '21 at 02:51
  • == Mostly a duplicate of [Python, why does this function go into an infinite loop - Stack Overflow](https://stackoverflow.com/questions/27108168/python-why-does-this-function-go-into-an-infinite-loop) or [python - Tkinter Function attached to Button executed immediately - Stack Overflow](https://stackoverflow.com/questions/37902076/tkinter-function-attached-to-button-executed-immediately) ;; Related: [python - Syntax behind sorted(key=lambda: ...) - Stack Overflow](https://stackoverflow.com/questions/8966538/syntax-behind-sortedkey-lambda) – user202729 Feb 12 '21 at 02:53
  • @TigerhawkT3 ... someone might want to post a better answer? – user202729 Feb 12 '21 at 02:53
  • @user202729 - Then they can vote to reopen that question. It was closed for a lack of debugging details, so it would first need to be improved with some debugging details for that to happen. Was this a hypothetical question, or did you have an answer in mind that you wanted to post? – TigerhawkT3 Feb 12 '21 at 02:55

0 Answers0