Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions Mi amor
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
from turtle import *
from math import *

speed(0)
bgcolor("black")
goto(0, -40)

# Draw leaves
for i in range(16):
for j in range(18):
color('#FFA216')
rt(90)
circle(150 - j * 6, 90)
lt(90)
circle(150 - j * 6, 90)
rt(180)
circle(40, 24)

# Draw flower center
color('black')
shape('circle')
shapesize(0.5)
fillcolor('#8B4513')
golden_ang = 137.508
phi = golden_ang * (pi / 180)

for i in range(140):
r = 4 * sqrt(i)
theta = i * phi
x = r * cos(theta)
y = r * sin(theta)
penup()
goto(x, y)
setheading(i * golden_ang)
pendown()
stamp()

# Texto en el centro de la flor
penup()
goto(0, -10) # Ajusta la posición del texto
color("orange")
write("C.E.V.M", align="center", font=("Arial", 20, "bold"))

hideturtle()
done()