gpt4 book ai didi

python - 类型错误 : unorderable types: str() > int()

转载 作者:太空宇宙 更新时间:2023-11-04 07:06:54 24 4
gpt4 key购买 nike

大家好,我收到错误了

TypeError: unorderable types: str() > int()

当我运行下面的代码时。我刚开始学python

number = input('Type in a number between 5 and 20 - ')
# run loop as long as the number is more than 0
while number > 0:
print('Number: ', number)
number -= 1

我该如何解决?

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com