![]() |
Drawing circles with loops (solved) - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: Homework (https://python-forum.io/forum-9.html) +--- Thread: Drawing circles with loops (solved) (/thread-13161.html) |
Drawing circles with loops (solved) - Villr - Oct-01-2018 Hi everyone, I'm currently trying to make a program to draw circles with loops. The problem I'm is, I have to make it so every circle drawn would be 10 pixels bigger than the previous one. I'm currently stuck on what to do. Here is my code: import turtle a = 1 size = 20 i=0 for i in range(0,200,10): turtle.bgcolor("green") turtle.color("blue") while a <= 5: a += 1 turtle.penup() turtle.goto(0,-size-i) turtle.pendown() turtle.circle(size+10) size += 10Edit: Sorry about that guys, I had a brain fart and managed to find a easier way to do it. |