Apr-16-2018, 03:51 PM
(This post was last modified: Apr-16-2018, 03:51 PM by IIINIKONIII.)
Hi,
I'm new to python and trying to make a basic tree, I have made this code to draw the triangles on top of each other but I am unable to work out how to make them larger as they go down. Can any one help?
Charley
I'm new to python and trying to make a basic tree, I have made this code to draw the triangles on top of each other but I am unable to work out how to make them larger as they go down. Can any one help?
number_of_shapes = 3 for shape in range(1, number_of_shapes + 1): # Draw a Triangle for sides in range(1, 4): forward(60) left(120) # Move forward to start position of next triangle penup() right(120) forward(60) left(120) forward(30) pendown()Thanks
Charley