Python,如何在if语句中添加更多选择

我有一个带if语句的python程序。我想在if语句中添加更多选择,我该怎么做?


def start():


    print ("A Wise man once said ...")

    o1 = input("\n" + 

      "[L]ook to the poverty of Africa ... [T]HIS HAS YET TO BE WRITTEN")


    if o1 == "L" or "l" or "Africa" or "1":

        print ("\n" + "You decide only a radical solution is viable...")

    else:

        print ("THIS IS NOT WRITTEN YET")


def menu ():


    print ("Menu\n")

    print ("(1)Start")

    print ("(2)Exit\n\n")

    choice = (input('>>'))

    if choice=="1":

        start()

    if choice=="2":

        quit()


menu()

我正在尝试下一步:


o2 = input (

  "\n" + "[D]ecide to take advantage ..., or T[H]IS HAS YET TO BE WRITTEN?"*)

我应该如何添加更多选择和选择,以便最终获得一个故事?


浮云间
浏览 234回答 2
2回答
打开App,查看更多内容
随时随地看视频慕课网APP

相关分类

Python