From bf61533e2eb30b29d863abc7b3fde3bff52bbcae Mon Sep 17 00:00:00 2001 From: BellCodeEditor <bellcode_dev@bell.ai> Date: Sat, 28 Aug 2021 17:02:01 +0800 Subject: [PATCH] save project --- __pycache__/qw.cpython-37.pyc | Bin 0 -> 614 bytes qw.py | 28 ++++++++++++++++++++++++++++ uteutuityuitye.py | 4 ++++ 3 files changed, 32 insertions(+) create mode 100644 __pycache__/qw.cpython-37.pyc create mode 100644 qw.py create mode 100644 uteutuityuitye.py diff --git a/__pycache__/qw.cpython-37.pyc b/__pycache__/qw.cpython-37.pyc new file mode 100644 index 0000000..d436399 Binary files /dev/null and b/__pycache__/qw.cpython-37.pyc differ diff --git a/qw.py b/qw.py new file mode 100644 index 0000000..910360a --- /dev/null +++ b/qw.py @@ -0,0 +1,28 @@ +def new_input(): + total=[] + while True: + unit=input('输入:(fucking退出)') + if unit=='fuking': + break + else: + try: + unit = int(unit) + except: + print('写数字:') + else: + total.append(unit) + finally: + print('===========================') + return total + + +def sum(money): + count=0 + for i in money: + count=count+1 + return count + + +#price=new_input() +#pay=sum(price) +#print('一共消费了'+str(pay)+'元!扫码or现金?') \ No newline at end of file diff --git a/uteutuityuitye.py b/uteutuityuitye.py new file mode 100644 index 0000000..1a1de5e --- /dev/null +++ b/uteutuityuitye.py @@ -0,0 +1,4 @@ +import qw +data=qw.new_input() +score=qw.sum(data) +print("分数为:"+str(score)) \ No newline at end of file -- libgit2 0.25.0