Skip to content

Instantly share code, notes, and snippets.

@lkmandy
Created November 20, 2017 19:18
Show Gist options
  • Select an option

  • Save lkmandy/f9c6d6c69f7132867e9af31a7d6e3901 to your computer and use it in GitHub Desktop.

Select an option

Save lkmandy/f9c6d6c69f7132867e9af31a7d6e3901 to your computer and use it in GitHub Desktop.
SquareFromCircle created by likhene - https://repl.it/@likhene/SquareFromCircle
iimport turtle
mandy_turtle = turtle.Turtle()
def squareCircle( length, angle1, angle2 ):
mandy_turtle.forward(length)
mandy_turtle.right(angle1)
mandy_turtle.forward(length)
mandy_turtle.right(angle1)
mandy_turtle.forward(length)
mandy_turtle.right(angle1)
mandy_turtle.forward(length)
mandy_turtle.right(angle2)
for i in range(100):
@lkmandy
Copy link
Author

lkmandy commented Nov 20, 2017

This script creates a circle from a square.
Basically playing around with angles, looping and functions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment