kong.Zhang 发表于 2019-4-21 11:49:21

新人请教下,我这程序为什么会提示错误

s = input("不妨猜一下小甲鱼现在心里想的是哪个数字:")
# not操作符的作用是将布尔类型的结果翻转:即取反的意思,not True == Flase
while not s.isdigit():
    print("抱歉,输入不合法,", end='')
    s = input("请输入一个整数:")
print("输入合法,", /r)

wp231957 发表于 2019-4-21 12:15:42

print("输入合法,", /r)这是神马鸟
页: [1]
查看完整版本: 新人请教下,我这程序为什么会提示错误