#!/usr/bin/env python # coding:utf-8 from turtle import * import time def
setTurtle(): # Window size screensize(900, 700, 'pink') # colour color('red', 'pink') #
Pen thickness pensize(3) # speed speed(6) # write penup() def getStart(h): # Coordinates to , The center of the window is 0,0
goto(0, -180) r = h / 5 drawBigL(r, h) drawBigArc(r, 140) drawBigArc(r, 70)
drawBigR(r, h) centerRange() drawHope() drawName() def drawBigL(r, h): colors =
['red', 'orange', 'yellow', '#87CEEB', 'violet', 'red'] for i in range(int(240
/ h) + 1): seth(0) color(colors[i], colors[i + 1]) drawHeart(r) seth(140) fd(h)
def drawBigArc(r, rad): colors = ['red', 'orange', 'yellow', 'SkyBlue',
'violet', 'red'] for i in range(50): if (i % 10 == 0): color(colors[int(i /
10)], colors[int(i / 10) + 1]) seth(0) drawHeart(r) seth(rad - (i + 1) * 4)
rt(4) fd(10.5) def drawBigR(r, h): colors = ['red', 'orange', 'yellow',
'SkyBlue', 'violet', 'red'] for i in range(int(240 / h) + 1): color(colors[i],
colors[i + 1]) seth(0) drawHeart(r) setheading(220) fd(h) def drawHeart(r):
down() begin_fill() factor = 180 seth(45) circle(-r, factor) fd(2 * r)
right(90) fd(2 * r) circle(-r, factor) end_fill() up() # Write in your heart def
centerRange(): for i in range(6): drawCenter(i) time.sleep(1) def
drawCenter(i): goto(0, 0) colors = ['red', 'orange', 'yellow', 'SkyBlue',
'violet', 'red'] pencolor(colors[i]) # Write in your heart font You can set fonts. You can set any font you have on your computer align Where to start writing
#write('love ...', font=('gungsuh', 30,), align="center") up() # Write a message def
drawHope(): pencolor('black') goto(-300, -220) showturtle() write(' Thirty nights of firecrackers ,',
font=(' Chinese Xingkai ', 25,), align="center", move=True) goto(-300, -270)
write(' I don't think so .', font=(' Chinese Xingkai ', 25,), align="center", move=True) # Sign def
drawName(): pencolor('black') goto(250, -250) showturtle() write(' Fu Changle
qq:876274474', font=('gungsuh', 20,), align="center", move=True) setTurtle()
getStart(80) # Click window to close window = Screen() window.exitonclick()

Technology
©2019-2020 Toolsou All rights reserved,
CSS architecture design NOI2019 travels Detailed explanation ubuntu14.04 How to set static IP2019 Year end summary —— Second year of work Big data tells you , How tired are Chinese women java Simple lottery algorithm , luck draw DemoPYTHON Summary of final review Classical algorithm - recursion ( The case of raw rabbit )2021 year 1 Monthly programmer salary statistics , average 14915 element First knowledge python Skills summary