Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
lesson4_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
a914ee00
authored
Jan 14, 2023
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
auto save
parent
acddd309
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
0 deletions
diy1.py
diy11.py
diy2 2022.11.1.py
diy1.py
View file @
a914ee00
...
@@ -5,6 +5,7 @@ userpassword = "123456" # 保存在服务器数据库中的用户密码(正
...
@@ -5,6 +5,7 @@ userpassword = "123456" # 保存在服务器数据库中的用户密码(正
i
=
3
i
=
3
while
True
:
while
True
:
if
i
>
0
:
if
i
>
0
:
print
(
"*"
*
20
)
name
=
input
(
"请输入用户名:"
)
name
=
input
(
"请输入用户名:"
)
password
=
input
(
"请输入你的密码:"
)
password
=
input
(
"请输入你的密码:"
)
i
-=
1
i
-=
1
...
@@ -13,9 +14,13 @@ while True:
...
@@ -13,9 +14,13 @@ while True:
break
break
if
name
!=
userpassword
:
if
name
!=
userpassword
:
print
(
"用户名不存在,请从新输入"
)
print
(
"用户名不存在,请从新输入"
)
print
(
"您还有"
+
str
(
i
)
+
"次机会"
)
print
(
"*"
*
20
)
continue
continue
if
password
!=
userpassword
:
if
password
!=
userpassword
:
print
(
"密码不正确,请从新输入"
)
print
(
"密码不正确,请从新输入"
)
print
(
"您还有"
+
str
(
i
)
+
"次机会"
)
print
(
"*"
*
20
)
else
:
else
:
print
(
"登录次数用完,60分钟后再尝试登录"
)
print
(
"登录次数用完,60分钟后再尝试登录"
)
exit
()
exit
()
...
...
diy11.py
0 → 100644
View file @
a914ee00
age
=
"12"
print
(
int
(
age
))
\ No newline at end of file
diy2 2022.11.1.py
0 → 100644
View file @
a914ee00
import
turtle
screen
=
turtle
.
Screen
()
screen
.
bgcolor
(
"black"
)
color_list
=
[
"red"
,
"orange"
,
"yellow"
,
"green"
]
pen
=
turtle
.
Pen
()
pen
.
speed
(
1000
)
for
i
in
range
(
1
,
500
):
pen
.
color
(
color_list
[
i
%
4
])
pen
.
forward
(
i
)
pen
.
right
(
91
)
turtle
.
done
()
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