Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
bellcode
/
lesson3-5-1_DIY1
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
9a7b9f7c
authored
Apr 27, 2024
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
save project
parent
215f065c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
0 deletions
diy.py
diy.py
0 → 100644
View file @
9a7b9f7c
import
turtle
screen
=
turtle
.
Screen
()
screen
.
bgcolor
(
"light blue"
)
pen
=
turtle
.
Pen
()
pen
.
penup
()
pen
.
goto
(
100
,
-
99
)
pen
.
write
(
"九月九日忆山东兄弟
\n
[唐]王维
\n
\n
独在异乡为异客,
\n
每逢佳节倍思亲。
\n
遥知兄弟登高处,
\n
遍插茱萸少一人。"
,
font
=
(
"Times"
,
18
,
"normal"
))
pen
.
hideturtle
()
pen1
=
turtle
.
Pen
()
screen
=
turtle
.
Screen
()
len
=
screen
.
textinput
(
"提示"
,
"你要多大的爱心:"
)
a
=
int
(
len
)
pen1
.
hideturtle
()
pen1
.
pensize
(
10
)
pen1
.
pencolor
(
"pink"
)
pen1
.
left
(
45
)
pen1
.
forward
(
a
)
pen1
.
circle
(
a
/
2
,
181
-
1
)
pen1
.
right
(
90
)
pen1
.
circle
(
a
/
2
,
189
-
9
)
pen1
.
forward
(
a
)
turtle
.
done
()
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment