import turtle as t steps = 200 corner = 7 alpha = 360 / corner for i in range(0, corner): t.fd(steps) t.left(alpha) t.done()