I'm doing a program in python where I draw a figure in this case a stickman and a square, instead of writing all the commands I want to take the coordinates of a list for example stickman = [x,y,x,y,x,y]
and take those coordinates from the list and draw them but I'm stuck, poor to do but nothing allowed me to use a cordage, stickman = [x,y]
someone can help me please.
here is the code that I have so far
import turtle
from turtle import *
t = Turtle()
def stickman():
t.left(60)
t.forward(50)
t.right(120)
t.forward(50)
t.back(50)
t.left(150)
t.forward(50)
t.right(85)
t.circle(20)
def cuadrado():
for i in [1,2,3,4]:
t.forward(50)
t.left(90)
def dibujar():
t.penup()
t.goto(100,200)
t.pendown()
stickman()
dibujar()
cuadrado()