From 94f016f59d178b164bcee37d45cabe953def8228 Mon Sep 17 00:00:00 2001 From: sigrid Date: Wed, 3 Sep 2025 17:22:14 +0800 Subject: [PATCH] checkpoint 2 - shapes I did it! It was easier than the previous checkpoint. The only hurdle was the mathematics, not the coding haha. --- shapes.py | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/shapes.py b/shapes.py index 731ec39..3111b99 100644 --- a/shapes.py +++ b/shapes.py @@ -2,10 +2,22 @@ # --------- # By MWC contributors -from turtle import * +from turtle import forward, right def triangle(side_length): - pass + forward(side_length), + right(120), + forward(side_length), + right(120), + forward(side_length), + right(120), def rectangle(height, width): - pass + forward(width), + right(90), + forward(height), + right(90) + forward(width), + right(90), + forward(height), + right(90)