[Tutor] help!

Nathaniel Olivier nathaniel.olivier at googlemail.com
Sat Dec 19 12:39:15 EST 2015


I don't understand what's wrong with this piece of code?
print ("The Flying Circus recently entered your town and are doing a never
seen before performance")
answer=raw_input("Shall you go? Type Yes or No to answer.")

def the_flying_circus():
    if answer == "Yes" or "yes" or "YES" or "yES":
        print ("You decided to go but your wallet was stolen by a circus
monkey. YOU LOSE!")
    elif answer == "no" or "No" or "NO" or "nO":
        print ("Your friends pressure you into coming but you stay
defiant.")
        print ("
























































































                                       Wait a minute.... YOU HAVE NO
FRIENDS! Cri evri tim ENDING")
    else:
        print ("U dumb m8? Try again idiot.")
    the_flying_circus()
the_flying_circus()
Note, Elif print 2 is made up of tabs.


More information about the Tutor mailing list