Since I had already played around with this for my

project, it was already a lot easier to figure out that in previous labs. I simply had to use the loop provided
along with indicating a repeat of four times with the forward and right commands already present. I did encounter
mild issues with forgetting a colon in a needed area, but was able to problem solve based on the error message I
received.
This commit is contained in:
Justin Toombs 2023-07-25 09:27:34 -04:00
parent 72bbd495e1
commit 316e5c399e
2 changed files with 10 additions and 1 deletions

View File

@ -7,7 +7,7 @@ readme = "README.md"
packages = [{include = "lab_iteration"}]
[tool.poetry.dependencies]
python = "^3.11"
python = "^3.10"
[build-system]

9
square.py Normal file
View File

@ -0,0 +1,9 @@
from turtle import *
def square(side_length):
for _ in range (4):
forward(side_length)
right(90)
square(40)
done()