Commit 0f00a1e2 by BellCodeEditor

save project

parent d76af08f
Showing with 8 additions and 2 deletions
...@@ -2,7 +2,12 @@ SVB=[] ...@@ -2,7 +2,12 @@ SVB=[]
while True: while True:
SB = input("输入吧:") SB = input("输入吧:")
if SB == 'q': if SB == 'q':
break break
else: else:
SVB.append(SB) try:
SB=int(SB)
except:
print("输数字")
else:
SVB.append(SB)
print(SVB) print(SVB)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment