Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
lesson14_1
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
168f9fdc
authored
Nov 23, 2024
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
save project
parent
a9a1d38e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
5 deletions
SSSS..py
diy.py
SSSS..py
0 → 100644
View file @
168f9fdc
# import turtle
# pen=turtle.Pen()
# pen.write("亲爱的同学们:\n今天学习了python中数据类型,\n回家后记得及时复习巩固,\n下周末再见!\n ———pipi",font=("Times",20,"normal"))
# pen.hideturtle()
# turtle.done()
# 画图
import
turtle
pen1
=
turtle
.
Pen
()
pen1
.
pencolor
(
"red"
)
pen1
.
pensize
(
5
)
pen1
.
left
(
45
)
pen1
.
forward
(
100
)
pen1
.
circle
(
50
,
180
)
pen1
.
right
(
90
)
pen1
.
circle
(
50
,
180
)
pen1
.
forward
(
100
)
turtle
.
done
()
\ No newline at end of file
diy.py
View file @
168f9fdc
...
@@ -4,7 +4,7 @@ class hero:
...
@@ -4,7 +4,7 @@ class hero:
self
.
name
=
name
self
.
name
=
name
self
.
hp
=
hp
self
.
hp
=
hp
self
.
attack
=
attack
self
.
attack
=
attack
kai
=
Hero
(
"凯"
,
9000
,
6000
)
kai
=
hero
(
"凯"
,
9000
,
6000
)
yingzeng
=
Hero
(
"嬴政"
5000
,
600
)
yingzeng
=
hero
(
"嬴政"
,
5000
,
600
)
print
(
name
,
hp
,
attack
)
print
(
kai
.
name
)
print
(
name
,
hp
,
attack
)
print
(
yingzeng
.
name
)
\ No newline at end of file
\ 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