From 332cbab05c859494f72c321cff22ef5597cccfe4 Mon Sep 17 00:00:00 2001 From: David Akim Date: Sat, 12 Oct 2024 11:40:42 -0400 Subject: [PATCH] David Art Christmas Sock (#10) * Add David Christmas Sock * Add David Christmas Sock fix --- drawfunctions/david_akim_christmas_sock.py | 37 ++++++++++++++++++++++ main.py | 3 +- 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 drawfunctions/david_akim_christmas_sock.py diff --git a/drawfunctions/david_akim_christmas_sock.py b/drawfunctions/david_akim_christmas_sock.py new file mode 100644 index 0000000..97845c3 --- /dev/null +++ b/drawfunctions/david_akim_christmas_sock.py @@ -0,0 +1,37 @@ +from turtle import Turtle + + +def draw_christmas_sock(): + turtle = Turtle() + turtle.hideturtle() + + # top sock part + turtle.up() + turtle.goto(125, 50) + turtle.down() + turtle.rt(-25) + turtle.fd(40) + turtle.circle(-5, 90) + turtle.fd(15) + turtle.circle(-5, 90) + turtle.fd(40) + turtle.circle(-5, 90) + turtle.fd(15) + turtle.circle(-5, 90) + turtle.up() + # bottom sock part + turtle.goto(171, 42) + turtle.begin_fill() + turtle.down() + turtle.color('red') + turtle.rt(90) + turtle.fd(50) + turtle.circle(-10, 90) + turtle.fd(50) + turtle.circle(-15, 180) + turtle.fd(15) + turtle.circle(10, 90) + turtle.fd(20) + turtle.rt(90) + turtle.fd(35) + turtle.end_fill() diff --git a/main.py b/main.py index 96dbd50..461b6e9 100644 --- a/main.py +++ b/main.py @@ -1,10 +1,11 @@ from turtle import exitonclick -from drawfunctions import dominic_duffin, david_akim, satoshi_s, teri_eyenike, david_akim_present_2024 +from drawfunctions import dominic_duffin, david_akim, satoshi_s, teri_eyenike, david_akim_present_2024, david_akim_christmas_sock dominic_duffin.christmas_tree() david_akim.star() satoshi_s.base() teri_eyenike.draw_shape() david_akim_present_2024.draw_present() +david_akim_christmas_sock.draw_christmas_sock() exitonclick()