0

So basically I wanted to ask that how can I add two things in a if or elif like

elif choice=="Coin" or "coin":

like this but as this is not working please tell me a better solution

This is what I tried:

elif choice=="Coin" or "coin" or "2":
   print("Ok then coin flip it is")

and the output of this was Welcome User Heads and Tails, Coin Flip or random no.- Coin flip Great let's do heads and tails.

  • The condition `choice=="Coin" or "coin"` is the same as `(choice=="Coin") or ("coin")`. In other words it treats `"coin"` as a completely separate logical condition. – Some programmer dude Sep 09 '22 at 07:18

0 Answers0