当前位置:网站首页>[turtle confessions collection] "the moon at the bottom of the sea is the moon in the sky, and the person in front of us is the sweetheart." Be happy for the rest of your life, and be safe for ever ~
[turtle confessions collection] "the moon at the bottom of the sea is the moon in the sky, and the person in front of us is the sweetheart." Be happy for the rest of your life, and be safe for ever ~
2022-06-10 23:59:00 【Programmer pear】
Preface
author :“ Programmer pear ”
** The article brief introduction **: This article is mainly about the use of Turtle I wrote a few small codes for confession ~
** article Source code Free access : To thank every project that pays attention to my little cute article Source code It's all nothing
Compensation sharing drop
Complete material for all articles + The source code is in
Fans white whoring source code welfare , Please move to CSDN Community
Text
I always like her in my heart , But I also know it's not her type . Secret love is a person's chaos , I know you well at school
having dinner 、 Time to pick up the express , At this point in time, all kinds of excuses to make an encounter , In fact, I just want to see you more . When I see you
hide , If I can't find you on campus . The epidemic didn't start school , Even this happiness is gone . Your microblog 、 I can recite any circle of friends
down . I look at your life , I don't feel happy, angry, sad or happy for me , But it's enough to affect my emotions . It's today
I know your first 600 God , I hope you are happy , Do you know why crows are like desks ?
—— From a fan contribution

These little papers and codes are for you , I hope you like it ( ω ).
One 、 Rose + copy
Obviously, there are no taboos , But you are 101 .
All the time with you
It's dazzling
Because the weather is good
Because of the bad weather
Because the weather is just fine
every single day , It's all beautiful .
——《 Ghosts 》
1) Effect display

2) Code display
from turtle import *
setup(650, 750, 0, 0)
colormode(255)
pencolor("black")
pu()
goto(-30, -66)
pd()
begin_fill()
color("black", "red")
seth(105)
circle(-80, 100)
circle(-200, 55)
seth(209)
circle(-332, 43)
end_fill()
pu()
begin_fill()
color("black", (139,69,19))
goto(-49, -64)
pd()
seth(135)
fd(23)
seth(252)
fd(32)
seth(242)
circle(1100, 8)
seth(0)
fd(10)
seth(70)
circle(-760, 13)
end_fill()
pu()
goto(-99, -153)
color("black", "green")
pd()
begin_fill()
seth(55)
circle(-80, 90)
seth(190)
end_fill()
fd(110)
pu()
goto(-95, -163)
pd()
begin_fill()
backward(100)
seth(225)
circle(-90, 70)
end_fill()
pu()
goto(-107,-89)
pd()
begin_fill()
seth(120)
fd(110)
seth(340)
circle(-90, 80)
end_fill()
pu()
goto(-107, -106)
pd()
begin_fill()
seth(120)
fd(90)
seth(250)
circle(60, 100)
end_fill()
pu()
goto(-73, -25)
color("black", "red")
pd()
begin_fill()
seth(90)
circle(260, 50)
seth(45)
fd(130)
seth(330)
circle(-120, 50)
seth(230)
fd(35)
seth(120)
fd(40)
seth(45)
backward(20)
seth(300)
circle(-200, 60)
end_fill()
pu()
goto(-45, -50)
pd()
begin_fill()
seth(135)
fd(25)
seth(60)
circle(200, 40)
seth(40)
circle(200, 50)
seth(300)
fd(110)
seth(240)
circle(500, 13)
seth(190)
circle(105, 85)
end_fill()
pu()
goto(105, 40)
pd()
begin_fill()
seth(350)
circle(-200, 30)
seth(35)
fd(30)
seth(115)
circle(-400, 32)
seth(160)
circle(120, 50)
seth(290)
fd(50)
seth(20)
fd(35)
seth(300)
circle(-120, 40)
seth(220)
fd(50)
seth(250)
fd(40)
end_fill()
pu()
goto(85, 44)
pd()
begin_fill()
seth(65)
circle(250, 27)
seth(200)
fd(15)
seth(270)
fd(30)
seth(220)
circle(100, 50)
seth(355)
fd(28)
end_fill()
pu()
goto(117, 100)
pd()
begin_fill()
seth(30)
fd(13)
seth(120)
fd(20)
seth(270)
fd(25)
end_fill()
pu()
goto(122, 145)
pd()
begin_fill()
seth(335)
fd(15)
seth(120)
fd(30)
seth(270)
fd(25)
Two 、 Receive my love + copy
The moon shines back into the lake , The wild crane rushes to the idle clouds , I walk into you .
—— Cangyangjiacuo
1) Effect display

2) Code display
import turtle
str = input(' Please input the table language :')
turtle.speed(10)# Brush speed
turtle.setup(1800,700,70,70)
turtle.color('black', 'pink')# Brush color
turtle.pensize(3) # Brush thickness
turtle.hideturtle() # Hide the brush ( First )
turtle.up() # write
turtle.goto(-655, -255) # Move the brush to the specified starting coordinates ( The center is the window 0,0)
turtle.down() # Write
turtle.showturtle() # Show paintbrush
# Draw the little man on the left
turtle.goto(-600,-200)
turtle.goto(-600,-120)
turtle.circle(35)
turtle.goto(-600,-200)
turtle.forward(40)
turtle.right(90)
turtle.forward(60)
turtle.hideturtle()
turtle.up()
turtle.goto(-600, -160)
turtle.down()
turtle.showturtle()
turtle.left(90)
turtle.forward(55)
turtle.right(45)
turtle.forward(20)
turtle.hideturtle()
turtle.up()
turtle.goto(-600, -145)
turtle.down()
turtle.showturtle()
turtle.goto(-545, -145)
turtle.left(90)
turtle.forward(20)
# Draw the first love
turtle.color('pink', 'pink')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-500, -153)
turtle.down()
turtle.showturtle()
turtle.right(90)
turtle.forward(30)
turtle.left(90)
turtle.forward(30)
turtle.left(45)
turtle.circle(10.6,180)
turtle.left(180)
turtle.circle(10.6,180)
turtle.end_fill()
# Next big love
turtle.color('green', 'green')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-430, -143)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(50)
turtle.left(90)
turtle.forward(50)
turtle.left(45)
turtle.circle(17.67,180)
turtle.left(180)
turtle.circle(17.67,180)
turtle.end_fill()
# The third love
turtle.color('red', 'red')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-315, -133)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(70)
turtle.left(90)
turtle.forward(70)
turtle.left(45)
turtle.circle(24.74,180)
turtle.left(180)
turtle.circle(24.74,180)
turtle.end_fill()
# The fourth love
turtle.color('red', 'red')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-187, -133)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(70)
turtle.left(90)
turtle.forward(70)
turtle.left(45)
turtle.circle(24.74,180)
turtle.left(180)
turtle.circle(24.74,180)
turtle.end_fill()
# The first 5 A love
turtle.color('green', 'green')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(-43.7, -143)
turtle.down()
turtle.showturtle()
turtle.left(135)
turtle.right(90)
turtle.forward(50)
turtle.left(90)
turtle.forward(50)
turtle.left(45)
turtle.circle(17.67,180)
turtle.left(180)
turtle.circle(17.67,180)
turtle.end_fill()
# The first 6 A love
turtle.color('pink', 'pink')
turtle.begin_fill()
turtle.hideturtle()
turtle.up()
turtle.goto(53.88, -153)
turtle.down()
turtle.showturtle()
turtle.right(90)
turtle.right(225)
turtle.forward(30)
turtle.left(90)
turtle.forward(30)
turtle.left(45)
turtle.circle(10.6,180)
turtle.left(180)
turtle.circle(10.6,180)
turtle.end_fill()
# Draw the little man on the right
turtle.hideturtle()
turtle.up()
turtle.goto(251.28, -255)
turtle.down()
turtle.showturtle()
turtle.goto(196.28,-200)
turtle.goto(196.28,-120)
turtle.left(90)
turtle.circle(35)
turtle.goto(196.28,-200)
turtle.left(180)
turtle.forward(40)
turtle.left(90)
turtle.forward(60)
turtle.hideturtle()
turtle.up()
turtle.goto(196.28,-160)
turtle.down()
turtle.showturtle()
turtle.right(90)
turtle.forward(55)
turtle.left(45)
turtle.forward(20)
turtle.hideturtle()
turtle.up()
turtle.goto(196.28, -145)
turtle.down()
turtle.showturtle()
turtle.right(45)
turtle.forward(55)
turtle.right(45)
turtle.forward(20)
# Draw balloon lines and balloons
# The first balloon
turtle.hideturtle()
turtle.up()
turtle.goto(-265, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-245, 0)
turtle.right(135)
turtle.circle(35)
# The first 2 A balloon
turtle.hideturtle()
turtle.up()
turtle.goto(-265, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-305, 80)
turtle.circle(40)
# The first 3 A balloon
turtle.hideturtle()
turtle.up()
turtle.goto(-137, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-167, 0)
turtle.circle(35)
# The first 4 A balloon
turtle.hideturtle()
turtle.up()
turtle.goto(-137, -133)
turtle.down()
turtle.showturtle()
turtle.goto(-117, 80)
turtle.circle(40)
# Write LOVE
turtle.pencolor("GREEN")
turtle.penup()
turtle.goto(-245,10)
turtle.write(" people ",move=False,align='center',font=(" Microsoft YaHei ",30,'normal'))
turtle.pencolor("PURPLE")
turtle.penup()
turtle.goto(-305,90)
turtle.write(" between ",move=False,align='center',font=(" Microsoft YaHei ",30,'normal'))
turtle.pencolor("YELLOW")
turtle.penup()
turtle.goto(-167,10)
turtle.write(" clear ",move=False,align='center',font=(" Microsoft YaHei ",30,'normal'))
turtle.pencolor("ORANGE")
turtle.penup()
turtle.write(" huan ",move=False,align='center',font=(" Microsoft YaHei ",30,'normal'))
# Write to whom
turtle.pencolor("black")
turtle.penup()
turtle.goto(300, 200)
turtle.write(str,move=False,align='center',font=(" Fangzheng shutI ",30,'normal'))
turtle.done()3、 ... and 、 Trees + copy
For you , Thousands of times .
—— The kite runner
1) Effect display

2) Code display
import pygame
import random
import time
import turtle
import multiprocessing
def music_play():
pygame.mixer.init()
while True:
music_name = str(random.randint(1, 3)) + '.mp3'
pygame.mixer.music.load('./music/%s' % music_name)
pygame.mixer.music.play(start=1.0)
time.sleep(120)
pygame.mixer.music.stop()
def draw_arc(lv):
for i in range(20):
lv.right(10)
lv.forward(2)
def draw_love(x, y):
love = turtle.Turtle()
love.hideturtle()
love.up()
love.goto(x, y)
love.color('pink', 'red')
love.speed(10000000)
love.pensize(2)
love.down()
love.begin_fill()
love.left(140)
love.forward(22)
draw_arc(love)
love.left(120)
draw_arc(love)
love.forward(22)
love.left(140)
love.end_fill()
def draw_tree(branchLen, tur):
if branchLen > 5:
if branchLen < 20:
tur.color('green')
tur.pensize(random.uniform((branchLen+5)/4-2, (branchLen+6)/4+5))
tur.down()
tur.forward(branchLen)
draw_love(tur.xcor(), tur.ycor())
tur.up()
tur.backward(branchLen)
tur.color('brown')
return
tur.pensize(random.uniform((branchLen+5)/4-2, (branchLen+6)/4+5))
tur.down()
tur.forward(branchLen)
angle = random.uniform(15, 45)
tur.right(angle)
draw_tree(branchLen-random.uniform(12, 16), tur)
tur.left(2*angle)
draw_tree(branchLen-random.uniform(12, 16), tur)
tur.right(angle)
tur.up()
tur.backward(branchLen)
def draw_main():
Win = turtle
tur = turtle.Turtle()
tur.hideturtle()
tur.speed(1000)
tur.left(90)
tur.up()
tur.backward(200)
tur.down()
tur.color("brown")
tur.pensize(32)
tur.forward(60)
draw_tree(100, tur)
Win.exitonclick()
if __name__ == '__main__':
process1 = multiprocessing.Process(target=draw_main)
process2 = multiprocessing.Process(target=music_play)
process1.start()
process2.start()summary
“ You are the joy of youth
This sentence in turn is you ”—— It's you
All right. ! This article will officially end here . If you like , Please help us with the triple ~,=
This is very important for Xiaobian at present . I wish you all. , Make a fortune , Universiade , A healthy body . Hee hee , Old rules Source code Find me Naza
Follow Xiaobian for more wonderful content ! Remember to click on the portal
If you need to package the complete source code + Free sharing of materials ~ Just call me !! Portal

边栏推荐
- 插入排序
- LabVIEW用VISA Read函数来读取USB中断数据
- Is it safe for changtou school to open an account? Is it reliable?
- High speed data stream disk for LabVIEW
- MySQL命令行导入导出数据
- IGBT and third generation semiconductor SiC double pulse test scheme
- LabVIEW获取IMAQ Get Last Event坐标
- Why many new websites are not included by search engines
- 30 | how to reset the consumer group displacement?
- Deepin20菜单启动选项后自检到iwlwifi停机
猜你喜欢

怎么生成自动参考文献(简单 有图)

LabVIEW prohibits other multi-core processing applications from executing on all cores

【Pygame小游戏】“史上最炫酷贪吃蛇”驾到,FUN开玩(不好玩不要钱)

LabVIEW get IMAQ get last event coordinates

【数学】【连续介质力学】流体力学中的对称张量、应变张量和应力张量

Ilruntime hotfix framework installation and breakpoint debugging

【Pygame小游戏】这款经典的炸弹人超能游戏上线,你爱了嘛?(附源码)

LabVIEW确定控件在显示器坐标系中的位置
![[opencv practice] this seal](/img/f4/c6a4529b8b24773bcb39b4d2c6e16f.png)
[opencv practice] this seal "artifact" is awesome, saving time and improving efficiency. It is powerful ~ (complete source code attached)

Error report of curl import postman
随机推荐
LabVIEW获取IMAQ Get Last Event坐标
【数学】【连续介质力学】流体力学中的对称张量、应变张量和应力张量
Flowable process deployment
【Pygame小遊戲】別找了,休閑遊戲專題來了丨泡泡龍小程序——休閑遊戲研發推薦
示波器和频谱分析仪的区别
Six procurement challenges perplexing Enterprises
【二叉树】二叉树剪枝
Error 1046 when LabVIEW uses MathScript node or matlab script
LabVIEW和VDM提取色彩和生成灰度图像
LeetCode 501 :二叉搜索樹中的眾數
快速排序
Fiddler creates an autoresponder
LabVIEW用VISA Read函数来读取USB中断数据
It is said that the verification code is a barrier in the crawler. I can break through it with only five lines of code.
Excel essential toolbox 17.0 Free Edition
【自动回复小脚本】新年快乐,每一个字都是我亲自手打的,不是转发哦~
OpenResty安装
LabVIEW determines the position of the control in the display coordinate system
LabVIEW obtains the information of all points found by the clamp function
LabVIEW performs a serial loopback test
