Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
bellcode
/
lesson3-1-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
a82a8620
authored
Jun 18, 2023
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
auto save
parent
c66a449e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
67 additions
and
19 deletions
4567
diy1.py
wyz.py/wyz.py
4567
0 → 100644
View file @
a82a8620
a=input("输入足岁年龄")
b=a*5+75
c=a*5+8
print("标准身高")
print("标准体重")
\ No newline at end of file
diy1.py
View file @
a82a8620
# 利用write()帮助悟空给诺依回信吧~
# 利用write()帮助悟空给诺依回信吧~
import
turtle
import
turtle
screen
=
turtle
.
Screen
()
scecren
=
turtle
.
Screen
()
screen
.
bgcolor
(
"light blue"
)
scecren
.
bgcolor
(
"pink"
)
len
=
screen
.
textinput
(
"100"
,
"100"
)
Pen
=
turtle
.
Pen
()
len
=
int
(
len
)
Pen
.
penup
()
pen
=
turtle
.
Pen
()
Pen
.
goto
(
0
,
-
100
)
pen
.
write
(
"你好
\n
SB."
,
font
=
(
"Times"
,
30
,
"normal"
))
Pen
.
write
(
""
,
font
=
(
"Times"
,
20
,
"normal"
))
pen
.
hideturtle
()
len
=
50
len
=
60
Pen1
=
turtle
.
Pen
()
pen
.
penup
()
Pen1
.
pensize
(
5
)
pen
.
goto
(
100
,
100
)
Pen1
.
pencolor
(
"red"
)
pen
.
pendown
()
Pen1
.
left
(
45
)
pen
.
pensize
(
5
)
Pen1
.
fd
(
2
*
len
)
pen
.
pencolor
(
"red"
)
Pen1
.
circle
(
len
,
180
)
pen
.
left
(
45
)
Pen1
.
right
(
90
)
pen
.
forward
(
2
*
len
)
Pen1
.
circle
(
len
,
180
)
pen
.
circle
(
len
,
180
)
Pen1
.
fd
(
2
*
len
)
pen
.
right
(
90
)
pen
.
circle
(
len
,
180
)
pen
.
forward
(
2
*
len
)
turtle
.
done
()
turtle
.
done
()
turtle
.
wyz.py/wyz.py
0 → 100644
View file @
a82a8620
print
(
"====游戏管理系统===="
)
print
(
"1.增加角色和段位"
)
print
(
"2.删除角色"
)
print
(
"3.修改段位"
)
print
(
"4.查询所有角色"
)
print
(
"5.根据角色查找段位"
)
print
(
"6.退出"
)
print
(
"==================="
)
wanzhe
=
{}
while
True
:
a
=
input
()
if
(
int
(
a
)
==
1
):
b
=
input
(
'角色:'
)
c
=
input
(
'段位:'
)
wanzhe
[
b
]
=
c
if
(
int
(
a
)
==
2
):
d
=
input
(
'删除的角色:'
)
del
wanzhe
[
d
]
if
(
int
(
a
)
==
3
):
e
=
input
(
'修改段位的人:'
)
f
=
input
(
'现段位:'
)
wanzhe
[
e
]
=
f
if
(
int
(
a
)
==
4
):
for
g
in
wanzhe
:
print
(
g
,
wanzhe
[
g
])
if
(
int
(
a
)
==
5
):
h
=
input
(
"你所寻找的角色:"
)
i
=
wanzhe
[
h
]
print
(
i
)
if
(
int
(
a
)
==
6
):
exit
()
\ 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