r/codehs • u/gwenkm323 • Sep 23 '23
Whats wrong with my loop?



My coding assignment says:
Ask the user if they want toppings: veg, meat or none. Output a drawing of the appropriate order. Display meat as red and veg as green circles on the pizza. None will just look like a plain pizza with slices.
Use a while loop to continue to ask the user if they want another pizza. When they finally say, "no", they say, " good bye".
The first part of my code works, but when I ask the user if they would like another pizza I can't get the positioning correct and it draws misplaced circle and lines even though the function itself is fine. I tried setposition in the loop rather than the function, and I'm still getting the same result. Any advice? My teacher assigned this today and its due tonight.
View all comments
Show parent comment
1
u/Zatujit Sep 23 '23
Python is a language that is based on indentation to make blocks, without indentation, i cannot help. Please use the "inline code" function in Reddit editor