Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
lesson11_2
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
d965c2de
authored
Nov 02, 2024
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
auto save
parent
7eaed43a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
0 deletions
test.py
test.py
0 → 100644
View file @
d965c2de
def
number
():
total
=
[]
while
True
:
unint
=
int
(
input
(
"请输入价格:"
))
if
unint
==
101
:
break
else
:
total
.
append
(
unint
)
return
total
lists
=
number
()
print
(
lists
)
自我介绍:
我做的是一个简单的
Python
价格统计程序,重复获取用户输入内容,
直到用户退出,最终将用户输入的内容全部保存到列表进行打印
\ 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