社区所有版块导航
Python
python开源   Django   Python   DjangoApp   pycharm  
DATA
docker   Elasticsearch  
aigc
aigc   chatgpt  
WEB开发
linux   MongoDB   Redis   DATABASE   NGINX   其他Web框架   web工具   zookeeper   tornado   NoSql   Bootstrap   js   peewee   Git   bottle   IE   MQ   Jquery  
机器学习
机器学习算法  
Python88.com
反馈   公告   社区推广  
产品
短视频  
印度
印度  
Py学习  »  Python

python 3.6.6输入不从输入返回任何内容

WastefulProgramming • 5 年前 • 1221 次点击  

我的代码现在很简单

#BlackJack

print("welcome to Wasteful's blackjack game")`
print("this program was built using standard python")

print("please select a option")
print("A to start, B to quit")
print("----------------------------")

menu_select = input("A/B: ").lower

if menu_select == "a":
    print("starting game when i can be assed to program it")
elif menu_select == "b":
    exit()
else:
    print("invalid")

但两个都是空的 a b ?我卡住了,需要点帮助,谢谢!

编辑:我注意到了这个愚蠢的错误。lower应该是。lower()

Python社区是高质量的Python/Django开发社区
本文地址:http://www.python88.com/topic/40733
 
1221 次点击  
文章 [ 2 ]  |  最新文章 5 年前