0

I'm using python 2.7 and trying to simply take an input from a person (via raw_input) and then output a string depending on what was typed into the input, but the behavior I am getting is that the first logic test in my "if" statement always executes, no matter what I type.

Any ideas why this is not working?

another_card = raw_input("Another card: (Y or N) ")

print "The value of another_card is: " + another_card 

if another_card == "Y" or "y":
    print "Good on you"
elif another_card == "N" or "n":
    print "Wimp. Game over."
else:
    print "What the hell did you type?"

Any help would be appreciated. Thanks.

0 Answers0