Welcome to the CSC Q&A, on our server named in honor of Ada Lovelace. Write great code! Get help and give help!
It is our choices... that show what we truly are, far more than our abilities.

Categories

+11 votes

Instead of saying that I want all of my dots to be all squares, I have managed to tell Thonny that I want this specific dot to be a square and for each dot I have to request a specific shape. So if I want 2 of my dots to show up, I type "square", it places a square, then I have to type "square" and it places the second square.

I tried putting my call to function outside of the loop, but I need my x and y variable to be put into the call function so the error says "variable referenced before assignment", and then I tried putting it inside of it's own loop, but then it just make the same point on an infinite loop....

So how do I get thonny to ask what shape I want for all of the dots while still allowing my individual dots to be created in a different function?

asked in CSC201 Spring 2021 by (1 point)

Please log in or register to answer this question.

...